11.07.2015 Views

Contactless Communication API - Oracle Software Delivery Cloud

Contactless Communication API - Oracle Software Delivery Cloud

Contactless Communication API - Oracle Software Delivery Cloud

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Package javax.microedition.contactless.ndefNDEFRecordgetId()public byte[] getId()Returns the identifier for the record payload. This can be used to refer to this payload from other records.Returnsdata identifier, null if identifier has been omitted from the NDEF recordgetNestedNDEFMessage(int)ParametersReturnsThrowsgetPayload()Returnspublic NDEFMessage getNestedNDEFMessage(int offset)Returns the nested NDEF message from the record payload. The beginning of the message is identified by the offset. Theoffset must be a value greater than or equal to 0 and less than the length of the payload byte array. If the NDEF recorddoes not have payload null is returned.offset - the start index of the NDEF message in the payload byte arraythe nested NDEF message, null if the NDEF record does not have payloadjava.lang.ArrayIndexOutOfBoundsException - if the offset is invalidjava.lang.IllegalArgumentException - if the record payload can not be formulated to NDEF messagepublic byte[] getPayload()Returns the payload in the NDEF record as byte array.the payload of the NDEF record, null if payload has been omitted from the NDEF recordgetPayloadLength()Returnspublic long getPayloadLength()Returns the length of the payload in the NDEF record. This method is offered for convenience, so that the payload lengthis available before actually retrieving it.getRecordType()ReturnssetId(byte[])the length of the payload, 0 if payload has been omitted from the NDEF recordpublic NDEFRecordType getRecordType()Returns the record type of this record. This object contains the actual type and the type format information.Returns the reference to record type object of this recordpublic void setId(byte[] id)35

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!