Click or drag to resize

Profile Class

ASCOM Scope Driver Helper Registry Profile Object
Inheritance Hierarchy
SystemObject
  ASCOM.UtilitiesProfile

Namespace: ASCOM.Utilities
Assembly: ASCOM.Utilities (in ASCOM.Utilities.dll) Version: 6.0.0.0 (6.6.9999.9999)
Syntax
public class Profile : IDisposable

The Profile type exposes the following members.

Constructors
 NameDescription
Public methodProfile Create a new Profile object
Public methodProfile(Boolean) Create a new profile object ignoring profile not found exceptions if generated
Top
Properties
 NameDescription
Public propertyDeviceType The type of ASCOM device for which profile data and registration services are provided (String, default = "Telescope")
Public propertyRegisteredDeviceTypes List the device types registered in the Profile store
Top
Methods
 NameDescription
Public methodCreateSubKey Create a registry key for the given DriverID.
Public methodDeleteSubKey Delete a registry key for the given DriverID. SubKey may contain \ separated path to key to be deleted.
Public methodDeleteValue(String, String) Delete the value from the registry. Name may be an empty string for the unnamed value.
Public methodDeleteValue(String, String, String) Delete the value from the registry. Name may be an empty string for the unnamed value. Value will be deleted from the subkey supplied.
Public methodDispose Disposes of resources used by the profile object
Public methodGetProfile Read an entire device profile and return it as an ASCOMProfile class instance
Public methodGetProfileXML Read an entire device profile and return it as an XML encoded string
Public methodGetValue(String, String) Retrieve a string value from the profile for the given Driver ID and variable name
Public methodGetValue(String, String, String) Retrieve a string value from the profile using the supplied subkey for the given Driver ID and variable name.
Public methodGetValue(String, String, String, String) Retrieve a string value from the profile using the supplied subkey for the given Driver ID and variable name. Set and return the default value if the requested variable name has not yet been set.
Public methodIsRegistered Confirms whether a specific driver is registered or unregistered in the profile store
Public methodRegister Registers a supplied DriverID and associates a descriptive name with the device
Public methodRegisteredDevices List the devices of a given device type that are registered in the Profile store
Public methodSetProfile Set an entire device profile from an ASCOMProfile class instance
Public methodSetProfileXML Set an entire device profile from an XML encoded string
Public methodSubKeys(String) Return a list of the sub-keys under the root of the given DriverID
Public methodSubKeys(String, String) Return a list of the sub-keys under the given DriverID
Public methodUnregister Remove all data for the given DriverID from the registry.
Public methodValues(String) Return a list of the (unnamed and named variables) under the root of the given DriverID.
Public methodValues(String, String) Return a list of the (unnamed and named variables) under the given DriverID and subkey.
Public methodWriteValue(String, String, String) Writes a string value to the profile using the given Driver ID and variable name.
Public methodWriteValue(String, String, String, String) Writes a string value to the profile using the supplied subkey for the given Driver ID and variable name.
Top
Remarks

This object provides facilities for registering ASCOM drivers with the Chooser, and for storing persistence information in a shared area of the file system.

Please code to the IProfile interface

See Also