Click or drag to resize

Common Class

Defines common global functions.
Inheritance Hierarchy
SystemObject
  GSFCommon

Namespace: GSF
Assembly: GSF.Core (in GSF.Core.dll) Version: 2.4.218-beta+101eee949414e414795e55a6e73d88938f0177b8
Syntax
public static class Common
View Source

The Common type exposes the following members.

Properties
 NameDescription
Public propertyStatic memberSystemTimer Gets a high-resolution number of seconds, including fractional seconds, that have elapsed since 12:00:00 midnight, January 1, 0001.
Top
Methods
 NameDescription
Public methodStatic memberCode exampleCreateArrayT(Int32)Creates a strongly-typed Array.
Public methodStatic memberCode exampleCreateArrayT(Int32, T)Creates a strongly-typed Array with an initial value parameter.
Public methodStatic memberGetApplicationType Gets the type of the currently executing application.
Public methodStatic memberGetAvailablePhysicalMemory Gets the available physical system memory.
Public methodStatic memberGetOSPlatformID Gets the operating system PlatformID
Public methodStatic memberGetOSProductName Gets the operating system product name.
Public methodStatic memberGetProcessMemory Gets the memory usage by the current process.
Public methodStatic memberGetTotalPhysicalMemory Gets the total physical system memory.
Public methodStatic memberIIfTReturns one of two strongly-typed objects.
Public methodStatic memberIsDefaultValueDetermines if given item is equal to its default value (e.g., null or 0.0).
Public methodStatic memberIsNonStringReferenceDetermines if given item is a reference type but not a string.
Public methodStatic memberIsNumeric Determines if given item is or can be interpreted as numeric.
Public methodStatic memberIsNumericType(Object) Determines if Type of item is a numeric type, i.e., item is IConvertible and has a TypeCode that is one of: Boolean, SByte, Byte, Int16, UInt16, Int32, UInt32, Int64, UInt64Single, Double or Decimal.
Public methodStatic memberIsNumericType(Type) Determines if type is a numeric type, i.e., has a TypeCode that is one of: Boolean, SByte, Byte, Int16, UInt16, Int32, UInt32, Int64, UInt64Single, Double or Decimal.
Public methodStatic memberIsNumericType(TypeCode) Determines if typeCode is a numeric type, i.e., one of: Boolean, SByte, Byte, Int16, UInt16, Int32, UInt32, Int64, UInt64Single, Double or Decimal.
Public methodStatic memberIsNumericTypeT Determines if T is a numeric type, i.e., has a TypeCode that is one of: Boolean, SByte, Byte, Int16, UInt16, Int32, UInt32, Int64, UInt64Single, Double or Decimal.
Public methodStatic memberIsReferenceDetermines if given item is a reference type.
Public methodStatic memberMaxTReturns the largest item from a list of parameters.
Public methodStatic memberMidTReturns the value that is neither the largest nor the smallest.
Public methodStatic memberMinTReturns the smallest item from a list of parameters.
Public methodStatic memberNotNull Returns value if not null; otherwise nonNullValue.
Public Extension MethodToNonNullNorEmptyStringT Converts value to string; null objects, DBNull objects or empty strings will return specified nonNullNorEmptyValue.
Public Extension MethodToNonNullNorWhiteSpaceT Converts value to string; null objects, DBNull objects, empty strings or all white space strings will return specified nonNullNorWhiteSpaceValue.
Public Extension MethodToNonNullString(String) Makes sure returned string value is not null; if this string is null, empty string ("") will be returned.
Public Extension MethodToNonNullStringT(T) Converts value to string; null objects (or DBNull objects) will return an empty string ("").
Public Extension MethodToNonNullStringT(T, String) Converts value to string; null objects (or DBNull objects) will return specified nonNullValue.
Public methodStatic memberTypeConvertFromString(String, Type) Converts this string into the specified type.
Public methodStatic memberTypeConvertFromString(String, Type, CultureInfo) Converts this string into the specified type.
Public methodStatic memberTypeConvertToString(Object) Converts value to a String using an appropriate TypeConverter.
Public methodStatic memberTypeConvertToString(Object, CultureInfo) Converts value to a String using an appropriate TypeConverter.
Top
Fields
 NameDescription
Public fieldStatic memberIsMono Determines if the code base is currently running under Mono.
Public fieldStatic memberIsPosixEnvironment Determines if the current system is a POSIX style environment.
Top
See Also

Reference

GSF Namespace