Class SCMEnvironment
Main class for the Smart Card Middleware API. Provides the initial entry points for connecting to the SCWS, obtaining the readers and listening to events.
Inheritance
System.Object
SCMEnvironment
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: scmapi
Assembly: scmapi.dll
Syntax
public class SCMEnvironment
Constructors
SCMEnvironment()
Create a new SCMEnvironment, initialize the list of all smart card readers attached to the device, and starts monitoring smart card reader events.
Declaration
public SCMEnvironment()
Methods
AddReaderEventListener(ReaderEvents)
Registers a reader event listener.
Declaration
public void AddReaderEventListener(ReaderEvents listener)
Parameters
| Type | Name | Description |
|---|---|---|
| ReaderEvents | listener | The listener object whose methods will be called when an event occurs. |
Ba2hex(Byte[])
Declaration
public static string Ba2hex(byte[] ba)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Byte[] | ba |
Returns
| Type | Description |
|---|---|
| System.String |
GetReader(String)
Gets the reader with the given name.
Declaration
public Reader GetReader(string name)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | the reader name, as a string. |
Returns
| Type | Description |
|---|---|
| Reader | the Reader object. |
GetReaders()
Returns the list of all smart card readers attached to the device.
Declaration
public List<Reader> GetReaders()
Returns
| Type | Description |
|---|---|
| System.Collections.Generic.List<Reader> | the Reader list. |
Hex2ba(String)
Declaration
public static byte[] Hex2ba(string hex)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | hex |
Returns
| Type | Description |
|---|---|
| System.Byte[] |
RemoveReaderEventListener(ReaderEvents)
Removes a reader event listener.
Declaration
public void RemoveReaderEventListener(ReaderEvents listener)
Parameters
| Type | Name | Description |
|---|---|---|
| ReaderEvents | listener | The listener object to remove. |