Provides utility functions for the framework.
Copy the source stream into the target stream.
public Void CopyStream(source, target)
Name | Type | Summary |
---|---|---|
source | Stream | Source stream to copy from. |
target | Stream | Target stream to copy to. |
Converts a DateTime into a Javascript timespan.
public Double DateTimeToJavascriptTimespan(datetime)
A Javascript timespan.
Name | Type | Summary |
---|---|---|
datetime | DateTime | A DateTime to convert. |
Converts a DateTime into a Unix timespan.
public Double DateTimeToUnixTimespan(datetime)
A Unix timespan.
Name | Type | Summary |
---|---|---|
datetime | DateTime | A DateTime to convert. |
Gets the full qualified domain name of the machine.
public String GetFQDN()
Returns the Type for the specified full qualified type name.
public Type GetType(fullQualifiedTypeName)
A Type corresponding to the received argument.
This method uses reflection to load the type assembly for getting it's type.
Name | Type | Summary |
---|---|---|
fullQualifiedTypeName | String | Full qualified type name string. |
Type | Summary |
---|---|
FrameworkException | Thrown when the type could not be retrived. |
Converts a Javascript timespan to a DateTime.
public DateTime JavascriptTimespanToDateTime(timespan)
A DateTime for the timespan.
Name | Type | Summary |
---|---|---|
timespan | Double | A Javascript timespan. |
Convert into boolean a string boolean representation.
public Boolean ToBoolean(boolean)
A boolean for the received string.
This method accounts for empty or null, false, f or 0 as false everything else is true.
Name | Type | Summary |
---|---|---|
boolean | String | String to convert to Boolean. |
Tries to get the specified Type.
public Type TryGetType(fullQualifiedTypeName)
A Type corresponding to the received argument or null if the type could not be loaded.
This method uses reflection to load the type assembly for getting it's type.
Name | Type | Summary |
---|---|---|
fullQualifiedTypeName | String | Full qualified type name string. |
Try to get the type specified on fullQualifiedTypeName
only if it is assignable from type
public Type TryGetType<T>(fullQualifiedTypeName)
A Type for the specified fullQualifiedTypeName.
Name | Type | Summary |
---|---|---|
fullQualifiedTypeName | String | Full qualified type name. |
Parses a full qualified type name and assign the values of the type and assembly names to the specified variables.
public Boolean TryGetTypeAndAssemblyNames(fullQualifiedTypeName, typeName, assemblyName)
true if the name could be parsed correctly, otherwise false.
Name | Type | Summary |
---|---|---|
fullQualifiedTypeName | String | Full qualified type name. |
typeName | String@ | Type name extracted from fullQualifiedTypeName. |
assemblyName | String@ | Assembly name extracted from fullQualifiedTypeName. |
Converts the unix timespan to a DateTime.
public DateTime UnixTimespanToDateTime(timespan)
A DateTime for the received timespan.
Name | Type | Summary |
---|---|---|
timespan | Double | A Unix timespan. |