C# Класс Tango.AreaDescription

C API wrapper for the Tango area description interface.
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
m_uuid string

Открытые методы

Метод Описание
Delete ( ) : bool

Delete an area description.

ExportToFile ( string filePath ) : bool

Export an area description from the default area storage location to the destination file directory. The exported file will use the UUID as its file name.

ForUUID ( string uuid ) : AreaDescription

Get an area description by UUID.

GetList ( ) : Tango.AreaDescription[]

Get a list of all the area descriptions on the device.

GetMetadata ( ) : Tango.Metadata

Get the metadata for the Area Description. If you want to create a metadata for a not yet saved Area Description, you should instead use the default constructor.

ImportFromFile ( string filePath ) : bool

Import an area description from a file path to the default area storage location.

SaveCurrent ( ) : AreaDescription

Saves the current area description, returning the area description saved. You can only save an area description while connected to the Tango Service and if you have enabled Area Learning mode. If you loaded an area description before connecting, then calling this method appends any new learned areas to that area description and returns an area description with the same UUID. If you did not load an area description, this method creates a new area description and a new UUID for that area description.

SaveMetadata ( Tango.Metadata metadata ) : bool

Save the metadata for this area description.

Приватные методы

Метод Описание
AreaDescription ( string uuid ) : System

Initializes a new instance of the Tango.AreaDescription class. Private to make sure people use AreaDescription.ForUUID

_FreeMetadataPtr ( IntPtr metadataPtr ) : void

Free a previously gotten Metadata pointer.

_GetMetadataPtr ( ) : IntPtr

Get the low level metadata pointer for an area description. Make sure to free this with FreeMetadataPtr when you are done with it.

_GetUUIDList ( ) : string[]

Get a list of all area description UUIDs on the device.

_MetadataGetDoubleArray ( IntPtr rawMetadata, string key, int expectedCount, double &value ) : bool

Get a fixed-size double array from an area description metadata.

_MetadataGetInt64 ( IntPtr rawMetadata, string key, System.Int64 &value ) : bool

Get an Int64 value from an area description metadata.

_MetadataGetString ( IntPtr rawMetadata, string key, string &value ) : bool

Get a string value from an area description metadata.

_MetadataSetDoubleArray ( IntPtr rawMetadata, string key, double value ) : bool

Set a fixed-size double array in an area description metadata.

_MetadataSetInt64 ( IntPtr rawMetadata, string key, System.Int64 value ) : bool

Set an Int64 value in an area description metadata.

_MetadataSetString ( IntPtr rawMetadata, string key, string value ) : bool

Set a string value in an area description metadata.

_ReadUTF8String ( IntPtr rawPtr ) : string

Convert an IntPtr to a UTF-8 encoded C-string into a C# string.

Описание методов

Delete() публичный Метод

Delete an area description.
public Delete ( ) : bool
Результат bool

ExportToFile() публичный Метод

Export an area description from the default area storage location to the destination file directory. The exported file will use the UUID as its file name.
public ExportToFile ( string filePath ) : bool
filePath string Destination file directory.
Результат bool

ForUUID() публичный статический Метод

Get an area description by UUID.
public static ForUUID ( string uuid ) : AreaDescription
uuid string UUID to find.
Результат AreaDescription

GetList() публичный статический Метод

Get a list of all the area descriptions on the device.
public static GetList ( ) : Tango.AreaDescription[]
Результат Tango.AreaDescription[]

GetMetadata() публичный Метод

Get the metadata for the Area Description. If you want to create a metadata for a not yet saved Area Description, you should instead use the default constructor.
public GetMetadata ( ) : Tango.Metadata
Результат Tango.Metadata

ImportFromFile() публичный статический Метод

Import an area description from a file path to the default area storage location.
public static ImportFromFile ( string filePath ) : bool
filePath string File path of the area descrption to be imported.
Результат bool

SaveCurrent() публичный статический Метод

Saves the current area description, returning the area description saved. You can only save an area description while connected to the Tango Service and if you have enabled Area Learning mode. If you loaded an area description before connecting, then calling this method appends any new learned areas to that area description and returns an area description with the same UUID. If you did not load an area description, this method creates a new area description and a new UUID for that area description.
public static SaveCurrent ( ) : AreaDescription
Результат AreaDescription

SaveMetadata() публичный Метод

Save the metadata for this area description.
public SaveMetadata ( Tango.Metadata metadata ) : bool
metadata Tango.Metadata Metadata to save.
Результат bool

Описание свойств

m_uuid публичное свойство

The UUID for this area description.
public string m_uuid
Результат string