Public Member Functions | |
NdefObject (NdefObject ndef) | |
NdefObject (byte _TNF, string _TYPE) | |
NdefObject (byte _TNF, string _TYPE, byte[] _PAYLOAD) | |
NdefObject (byte _TNF, string _TYPE, byte[] ID, byte[] _PAYLOAD) | |
NdefObject (byte _TNF, byte[] _TYPE, byte[] ID, byte[] _PAYLOAD) | |
void | SetMessageBegin (bool mb) |
void | SetMessageEnd (bool me) |
int | Size (ref bool is_short_record) |
byte [] | GetBytes (bool isBegin, bool isEnd) |
byte [] | GetBytes () |
virtual bool | Encode (ref byte[] buffer) |
delegate void | NdefFoundCallback (NdefObject ndef) |
Static Public Member Functions | |
static bool | Parse (byte[] buffer, NdefFoundCallback callback) |
static bool | Parse (byte[] buffer, ref int offset, ref NdefObject ndef, ref bool terminated) |
static NdefObject [] | Parse (byte[] buffer) |
Protected Attributes | |
byte [] | _payload = null |
List< NdefObject > | _children = new List<NdefObject>() |
Properties | |
byte | TNF [get, set] |
string | TYPE [get, set] |
byte [] | ID [get, set] |
byte [] | PAYLOAD [get, set] |
c* SpringCard.NfcForum.Ndef/NdefObject
NAME Ndef
DESCRIPTION Represents a NDEF message, or portion of message
DERIVED BY Rtd
SYNOPSIS Ndef ndef = new Ndef(bytes[]) Ndef ndef = new Ndef(byte TNF, string TYPE) Ndef ndef = new Ndef(byte TNF, string TYPE, byte[] PAYLOAD) Ndef ndef = new Ndef(Ndef ndef)
|
virtual |
m* SpringCard.NfcForum.Ndef/NdefObject.Encode
SYNOPSIS public virtual bool Encode(ref byte[] buffer)
DESCRIPTION Serializes the NDEF and returns true if the operation succeeds
Reimplemented in SpringCard.NfcForum.Ndef.RtdVCard, SpringCard.NfcForum.Ndef.RtdSmartPoster, SpringCard.NfcForum.Ndef.RtdHandoverSelector, and SpringCard.NfcForum.Ndef.RtdAlternativeCarrier.
byte [] SpringCard.NfcForum.Ndef.NdefObject.GetBytes | ( | bool | isBegin, |
bool | isEnd | ||
) |
m* SpringCard.NfcForum.Ndef/NdefObject.GetBytes
SYNOPSIS public byte[] GetBytes(bool isBegin, bool isEnd) public byte[] GetBytes()
DESCRIPTION Uses the "Encode" method to serialize the ndef and returns the byte array. The two parameters isBegin and isEnd indicate if the NDEF is the first or the last in a series of NDEF
SEE ALSO Ndef.Encode
delegate void SpringCard.NfcForum.Ndef.NdefObject.NdefFoundCallback | ( | NdefObject | ndef | ) |
m* SpringCard.NfcForum.Ndef/NdefObject.NdefFoundCallback
SYNOPSIS public delegate void NdefFoundCallback(Ndef ndef)
DESCRIPTION Specifies the callback that will be called once a NDEF is found
SEE ALSO Ndef.Parse
|
static |
m* SpringCard.NfcForum.Ndef/NdefObject.Parse
SYNOPSIS public static bool Parse(byte [] buffer, NdefFoundCallback callback) public static bool Parse(byte[] buffer, ref int offset, ref Ndef ndef, ref bool terminated) public static Ndef[] Parse(byte[] buffer)
DESCRIPTION Analyses a bytes array to retrieve one or several NDEFs in it
SEE ALSO Ndef.Parse
void SpringCard.NfcForum.Ndef.NdefObject.SetMessageBegin | ( | bool | mb | ) |
m* SpringCard.NfcForum.Ndef/NdefObject.SetMessageBegin
SYNOPSIS public void SetMessageBegin(bool mb)
DESCRIPTION Sets the "MESSAGE BEGIN" bit in header
SEE ALSO Ndef.SetMessageEnd
void SpringCard.NfcForum.Ndef.NdefObject.SetMessageEnd | ( | bool | me | ) |
m* SpringCard.NfcForum.Ndef/NdefObject.SetMessageEnd
SYNOPSIS public void SetMessageEnd(bool me)
DESCRIPTION Sets the "MESSAGE END" bit in header
SEE ALSO Ndef.SetMessageBegin
int SpringCard.NfcForum.Ndef.NdefObject.Size | ( | ref bool | is_short_record | ) |
m* SpringCard.NfcForum.Ndef/NdefObject.Size
SYNOPSIS public int Size(ref bool is_short_record)
DESCRIPTION Calculates the size in bytes of the whole NDEF The parameter is_short_record indicates if the NDEF is a short record (length of payload < 256)
|
getset |
v* SpringCard.NfcForum.Ndef/NdefObject.ID
SYNOPSIS public byte[] ID
DESCRIPTION Gets and sets the Id of the NDEF
|
getset |
v* SpringCard.NfcForum.Ndef/NdefObject.PAYLOAD
SYNOPSIS public byte[] PAYLOAD
DESCRIPTION Gets and sets the Payload of the NDEF
|
getset |
v* SpringCard.NfcForum.Ndef/NdefObject.TNF
SYNOPSIS public byte TNF
DESCRIPTION Gets and sets the Type Name Format of the NDEF
|
getset |
v* SpringCard.NfcForum.Ndef/NdefObject.TYPE
SYNOPSIS public string TYPE
DESCRIPTION Gets and sets the Type of the NDEF