Type=Class
Version=4.7
ModulesStructureVersion=1
B4J=true
@EndOfDesignText@
'Class Person module
Sub Class_Globals
	Private fx As JFX
	Private mFirstName, mLastName As String
	Private mBirthDate As Long	
End Sub

'Initializes the Person object.
Sub Initialize (FirstName As String, LastName As String, BirthDate As Long)
	mFirstName = FirstName
	mLastName = LastName
	mBirthDate = BirthDate
End Sub

Public Sub GetName As String
	Return mFirstName & " " & mLastName
End Sub

Public Sub GetCurrentAge As Int
	Return GetAgeAt(DateTime.Now)
End Sub

Public Sub GetAgeAt(Date As Long) As Int
	Dim diff As Long
	diff = Date - mBirthDate
	Return Floor(diff / DateTime.TicksPerDay / 365)
End Sub
