EKM Client API

- Main Page
- Namespaces
- Classes

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Static Public Member Functions | Public Attributes | Properties
com::ansys::ingress::connector::model::Variant Class Reference

Variant represents any type of data value that can be stored in a property of an EKM object. The valid types include: More...

List of all members.

## Public Member Functions

| Variant ()
| Creates a new instance of Variant.
| Variant (VariantDataType type, object value)
| Creates a new instance of Variant.
VariantData | CreateSerializable ()
| Creates a VariantData from this Variant.
override bool | Equals (object obj)
| Determines if the given object equals this object.
Boolean | GetBoolean ()
| Returns the value of this Variant as a boolean.
DateTime | GetDate ()
| Returns the value of this Variant as a date/time value.
double | GetDouble ()
| Returns the value of this Variant as a double value.
override int | GetHashCode ()
| Returns the hash code of this object.
long | GetLong ()
| Returns the value of this Variant as a long value.
Dictionary< String, Variant > | GetMap ()
| Returns the value of this Variant as a Dictionary value.
object | GetObject ()
| Returns the value of this Variant.
Reference | GetReference ()
| Returns the value of this Variant as a Reference.
string | GetReferenceId ()
| Returns the archive ID of the Reference value stored in this Variant.
List< Reference > | GetReferenceList (List< Reference > list)
| Returns the value of this Variant as a List of References.
string | GetString ()
| Returns the value of this Variant as a string.
List< string > | GetStringList ()
| Returns the value of this Variant as a List of strings.
string | GetTypeName ()
| Returns the type name of this Variant.
Variant[] | GetVariants ()
| Returns the value of this Variant as an array of Variants.
bool | IsEmpty ()
| Returns true if this Variant is emtpy.
bool | IsMultivalued ()
| Returns true if this Variant is multivalued (i.e. type is LIST or MAP).
bool | IsReference ()
| Returns true if this Variant is a Reference.
string | Serialize ()
| Serializes this Variant to XML.
string | Serialize (VariantData var)
| Serializes a VariantData to XML.
override string | ToString ()
| Converts this Variant to a string.

## Static Public Member Functions

static Variant | CreateVariant (List< string > strings)
| Creates a Variant from a list of strings.
static Variant | Deserialize (string xml)
| Takes an XML string and converts it to a Variant instance.
static VariantDataMapEntry[] | CreateMap (Dictionary< string, Variant > dictionary)
| Creates an array of VariantDataMapEntrys from a Dictionary.
static Variant | CreateVariant (VariantData svar)
| Creates a Variant from a VariantData.
static Dictionary< string, Variant > | CreateMap (VariantDataMapEntry[] items)
| Creates a dictionary of Variants from a serializable dictionary.
static IEnumerable< Variant > | CreateCollection (VariantData[] serializableVariant)
| Creates a collection of Variants from an arrary of serializable variants.

## Public Attributes

const VariantDataType | LIST = VariantDataType.LIST
| Defines the constants for Variant types.
const string | TYPE_NAME_LIST = "List"
| Defines the constants for type names.

## Properties

VariantDataType | Type`[get, set]`
| Type is the type of the Varaint.
object | Value`[get, set]`
| Value is the actual value.

## Detailed Description

Variant represents any type of data value that can be stored in a property of an EKM object. The valid types include:

LIST - a list of Variants BOOLEAN - a boolean value DATE - a date value LONG - a long value DOUBLE - a real value STRING - a string value HARD_REFERENCE - a hard reference to an object in the repository SOFT_REFERENCE - a soft reference to an object in the repository MAP - a collection of key/value pairs where the keys are strings and the value is a Variant

## Constructor & Destructor Documentation

com::ansys::ingress::connector::model::Variant::Variant | ( |  | ) | `[inline]`

Creates a new instance of Variant.

com::ansys::ingress::connector::model::Variant::Variant | ( | VariantDataType | type,
|  | object | value
| ) |  | `[inline]`

Creates a new instance of Variant.

Parameters:

  type | The type of the Variant
  value | The value of the Variant

## Member Function Documentation

static IEnumerable<Variant> com::ansys::ingress::connector::model::Variant::CreateCollection | ( | VariantData[] | serializableVariant | ) | `[inline, static]`

Creates a collection of Variants from an arrary of serializable variants.

Parameters:

  serializableVariant | The serializable variants

Returns:
  Returns the collection.

static VariantDataMapEntry [] com::ansys::ingress::connector::model::Variant::CreateMap | ( | Dictionary< string, Variant > | dictionary | ) | `[inline, static]`

Creates an array of VariantDataMapEntrys from a Dictionary.

Parameters:

  dictionary | The Dictionary

Returns:
  Returns the array.

static Dictionary<string, Variant> com::ansys::ingress::connector::model::Variant::CreateMap | ( | VariantDataMapEntry[] | items | ) | `[inline, static]`

Creates a dictionary of Variants from a serializable dictionary.

Parameters:

  items | The serializable dictionary

Returns:
  Returns the dictionary of variants.

VariantData com::ansys::ingress::connector::model::Variant::CreateSerializable | ( |  | ) | `[inline]`

Creates a VariantData from this Variant.

Returns:
  Returns a VariantData.

static Variant com::ansys::ingress::connector::model::Variant::CreateVariant | ( | List< string > | strings | ) | `[inline, static]`

Creates a Variant from a list of strings.

Parameters:

  strings | the strings

Returns:
  Returns a new LIST Variant.

static Variant com::ansys::ingress::connector::model::Variant::CreateVariant | ( | VariantData | svar | ) | `[inline, static]`

Creates a Variant from a VariantData.

Parameters:

  svar | The VariantData

Returns:
  Returns a Variant.

static Variant com::ansys::ingress::connector::model::Variant::Deserialize | ( | string | xml | ) | `[inline, static]`

Takes an XML string and converts it to a Variant instance.

Parameters:

  xml | The XML string

Returns:
  Returns a Variant.

override bool com::ansys::ingress::connector::model::Variant::Equals | ( | object | obj | ) | `[inline]`

Determines if the given object equals this object.

Parameters:

  obj | The object to test

Returns:
  Returns true if the given object equals this object.

Boolean com::ansys::ingress::connector::model::Variant::GetBoolean | ( |  | ) | `[inline]`

Returns the value of this Variant as a boolean.

Returns:
  Returns a boolean.

DateTime com::ansys::ingress::connector::model::Variant::GetDate | ( |  | ) | `[inline]`

Returns the value of this Variant as a date/time value.

Returns:
  Returns a DateTime.

double com::ansys::ingress::connector::model::Variant::GetDouble | ( |  | ) | `[inline]`

Returns the value of this Variant as a double value.

Returns:
  Returns a double.

override int com::ansys::ingress::connector::model::Variant::GetHashCode | ( |  | ) | `[inline]`

Returns the hash code of this object.

Returns:
  Returns an int.

long com::ansys::ingress::connector::model::Variant::GetLong | ( |  | ) | `[inline]`

Returns the value of this Variant as a long value.

Returns:
  Returns a long.

Dictionary<String, Variant> com::ansys::ingress::connector::model::Variant::GetMap | ( |  | ) | `[inline]`

Returns the value of this Variant as a Dictionary value.

Returns:
  Returns a Dictionary.

object com::ansys::ingress::connector::model::Variant::GetObject | ( |  | ) | `[inline]`

Returns the value of this Variant.

Returns:
  Returns an object.

Reference com::ansys::ingress::connector::model::Variant::GetReference | ( |  | ) | `[inline]`

Returns the value of this Variant as a Reference.

Returns:
  Returns a Reference.

string com::ansys::ingress::connector::model::Variant::GetReferenceId | ( |  | ) | `[inline]`

Returns the archive ID of the Reference value stored in this Variant.

Returns:
  Returns a string.

List<Reference> com::ansys::ingress::connector::model::Variant::GetReferenceList | ( | List< Reference > | list | ) | `[inline]`

Returns the value of this Variant as a List of References.

Parameters:

  list | The List to populate

Returns:
  Returns a List.

string com::ansys::ingress::connector::model::Variant::GetString | ( |  | ) | `[inline]`

Returns the value of this Variant as a string.

Returns:
  Returns a string.

List<string> com::ansys::ingress::connector::model::Variant::GetStringList | ( |  | ) | `[inline]`

Returns the value of this Variant as a List of strings.

Returns:
  Returns a List.

string com::ansys::ingress::connector::model::Variant::GetTypeName | ( |  | ) | `[inline]`

Returns the type name of this Variant.

Returns:
  Returns a string.

Variant [] com::ansys::ingress::connector::model::Variant::GetVariants | ( |  | ) | `[inline]`

Returns the value of this Variant as an array of Variants.

Returns:
  Returns an array.

bool com::ansys::ingress::connector::model::Variant::IsEmpty | ( |  | ) | `[inline]`

Returns true if this Variant is emtpy.

Returns:
  Returns a bool.

bool com::ansys::ingress::connector::model::Variant::IsMultivalued | ( |  | ) | `[inline]`

Returns true if this Variant is multivalued (i.e. type is LIST or MAP).

Returns:
  Returns a bool.

bool com::ansys::ingress::connector::model::Variant::IsReference | ( |  | ) | `[inline]`

Returns true if this Variant is a Reference.

Returns:
  Returns a bool.

string com::ansys::ingress::connector::model::Variant::Serialize | ( |  | ) | `[inline]`

Serializes this Variant to XML.

Returns:
  Returns a string.

string com::ansys::ingress::connector::model::Variant::Serialize | ( | VariantData | var | ) | `[inline]`

Serializes a VariantData to XML.

Parameters:

  var | The VariantData

Returns:
  Returns a string.

override string com::ansys::ingress::connector::model::Variant::ToString | ( |  | ) | `[inline]`

Converts this Variant to a string.

Returns:
  Returns a string.

## Member Data Documentation

const VariantDataType com::ansys::ingress::connector::model::Variant::LIST = VariantDataType.LIST

Defines the constants for Variant types.

const string com::ansys::ingress::connector::model::Variant::TYPE_NAME_LIST = "List"

Defines the constants for type names.

## Property Documentation

VariantDataType com::ansys::ingress::connector::model::Variant::Type`[get, set]`

Type is the type of the Varaint.

object com::ansys::ingress::connector::model::Variant::Value`[get, set]`

Value is the actual value.

The documentation for this class was generated from the following file:

- Variant.cs

All Classes Namespaces Functions Variables Enumerations Properties