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

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Package javax.microedition.contactless.ndefNDEFTagConnectionwriteNDEF( NDEFMessage )ParametersThrowspublic void writeNDEF( NDEFMessage message) throwsjavax.microedition.contactless.<strong>Contactless</strong>Exception, java.io.IOExceptionWrites NFC Forum formatted data in the NDEF message to the target. This method overwrites all the existing data on thetarget and it blocks until writing is completed or the connection to target is lost.Writing data to the target may fail for various reasons. The <strong>API</strong> implementation must read the newly written data rightafter the write operation and make sure that all data was written correctly to the target. Returning from this method mustmean that writing was successful. If writing failed an IOException is thrown.message - NDEF message to be written to the target<strong>Contactless</strong>Exception - if NFC Forum formatting is not supported by the targetjava.lang.NullPointerException - if message is nulljava.lang.IllegalArgumentException - if message does not contain any NDEF recordsjava.lang.IllegalStateException - if other write operation is ongoingjava.io.IOException - if writing data to the target failed, connection to the target is lost or it has been closedjava.lang.SecurityException - if the application does not have permission to write to a targetjavax.microedition.contactless.<strong>Contactless</strong>Exception43

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

Saved successfully!

Ooh no, something went wrong!