Show / Hide Table of Contents

GetDataCommand Constructor

GetDataCommand()

Initializes a new instance of the GetDataCommand class.

C#
public GetDataCommand()

Remarks

This constructor is provided for those developers who want to use the object initializer pattern. For example:

var getDataCommand = new GetDataCommand()
{
    DataTag = (int)PivDataTag.Authentication,
};

There is no default data tag, hence, for this command to be valid, the tag must be specified. So if you create an object using this constructor, you must set the DataTag property at some time before using it. Otherwise you will get an exception when you do use it.

The valid data tags are numbers from 0x005F0000 to 0x005FFFFF inclusive, along with 0x0000007E and 0x00007F61.

GetDataCommand(PivDataTag)

Warning

This constructor is obsolete, use GetDataCommand() or GetDataCommand(int) instead.

Initializes a new instance of the GetDataCommand class. This command takes in a tag indicating which data element to get.

C#
[Obsolete("This constructor is obsolete. Use GetDataCommand(int) instead", false)]
public GetDataCommand(PivDataTag tag)

Parameters

Type Name Description
PivDataTag tag

The tag indicating which data to get.

Remarks

Note that this constructor is Obsolete.

GetDataCommand(int)

Initializes a new instance of the GetDataCommand class.

C#
public GetDataCommand(int dataTag)

Parameters

Type Name Description
int dataTag

The DataTag indicating from where the data will be retrieved.

Exceptions

Type Condition
ArgumentException

The DataTag specified is not a number between 0x005F0000 and 0x005FFFFF (inclusive), or 0x0000007E or 0x00007F61.

Remarks

Note that this constructor requires using a DataTag that is a number from 0x005F0000 to 0x005FFFFF inclusive, along with 0x0000007E and 0x00007F61.

In this article
Back to top Generated by DocFX