Java Code Examples for com.sun.xml.internal.bind.v2.util.ByteArrayOutputStreamEx#size()
The following examples show how to use
com.sun.xml.internal.bind.v2.util.ByteArrayOutputStreamEx#size() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: Base64Data.java From TencentKona-8 with GNU General Public License v2.0 | 6 votes |
/** * Gets the raw data. The size of the byte array maybe larger than the actual length. */ public byte[] get() { if (data == null) { try { ByteArrayOutputStreamEx baos = new ByteArrayOutputStreamEx(1024); InputStream is = dataHandler.getDataSource().getInputStream(); baos.readFrom(is); is.close(); data = baos.getBuffer(); dataLen = baos.size(); } catch (IOException e) { // TODO: report the error to the unmarshaller dataLen = 0; // recover by assuming length-0 data } } return data; }
Example 2
Source File: Base64Data.java From jdk8u60 with GNU General Public License v2.0 | 6 votes |
/** * Gets the raw data. The size of the byte array maybe larger than the actual length. */ public byte[] get() { if (data == null) { try { ByteArrayOutputStreamEx baos = new ByteArrayOutputStreamEx(1024); InputStream is = dataHandler.getDataSource().getInputStream(); baos.readFrom(is); is.close(); data = baos.getBuffer(); dataLen = baos.size(); } catch (IOException e) { // TODO: report the error to the unmarshaller dataLen = 0; // recover by assuming length-0 data } } return data; }
Example 3
Source File: Base64Data.java From openjdk-jdk8u with GNU General Public License v2.0 | 6 votes |
/** * Gets the raw data. The size of the byte array maybe larger than the actual length. */ public byte[] get() { if (data == null) { try { ByteArrayOutputStreamEx baos = new ByteArrayOutputStreamEx(1024); InputStream is = dataHandler.getDataSource().getInputStream(); baos.readFrom(is); is.close(); data = baos.getBuffer(); dataLen = baos.size(); } catch (IOException e) { // TODO: report the error to the unmarshaller dataLen = 0; // recover by assuming length-0 data } } return data; }
Example 4
Source File: Base64Data.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 6 votes |
/** * Gets the raw data. The size of the byte array maybe larger than the actual length. */ public byte[] get() { if (data == null) { try { ByteArrayOutputStreamEx baos = new ByteArrayOutputStreamEx(1024); InputStream is = dataHandler.getDataSource().getInputStream(); baos.readFrom(is); is.close(); data = baos.getBuffer(); dataLen = baos.size(); } catch (IOException e) { // TODO: report the error to the unmarshaller dataLen = 0; // recover by assuming length-0 data } } return data; }
Example 5
Source File: Base64Data.java From openjdk-jdk9 with GNU General Public License v2.0 | 6 votes |
/** * Gets the raw data. The size of the byte array maybe larger than the actual length. */ public byte[] get() { if (data == null) { try { ByteArrayOutputStreamEx baos = new ByteArrayOutputStreamEx(1024); InputStream is = dataHandler.getDataSource().getInputStream(); baos.readFrom(is); is.close(); data = baos.getBuffer(); dataLen = baos.size(); } catch (IOException e) { // TODO: report the error to the unmarshaller dataLen = 0; // recover by assuming length-0 data } } return data; }
Example 6
Source File: Base64Data.java From hottub with GNU General Public License v2.0 | 6 votes |
/** * Gets the raw data. The size of the byte array maybe larger than the actual length. */ public byte[] get() { if (data == null) { try { ByteArrayOutputStreamEx baos = new ByteArrayOutputStreamEx(1024); InputStream is = dataHandler.getDataSource().getInputStream(); baos.readFrom(is); is.close(); data = baos.getBuffer(); dataLen = baos.size(); } catch (IOException e) { // TODO: report the error to the unmarshaller dataLen = 0; // recover by assuming length-0 data } } return data; }
Example 7
Source File: Base64Data.java From openjdk-8-source with GNU General Public License v2.0 | 6 votes |
/** * Gets the raw data. The size of the byte array maybe larger than the actual length. */ public byte[] get() { if (data == null) { try { ByteArrayOutputStreamEx baos = new ByteArrayOutputStreamEx(1024); InputStream is = dataHandler.getDataSource().getInputStream(); baos.readFrom(is); is.close(); data = baos.getBuffer(); dataLen = baos.size(); } catch (IOException e) { // TODO: report the error to the unmarshaller dataLen = 0; // recover by assuming length-0 data } } return data; }
Example 8
Source File: Base64Data.java From openjdk-8 with GNU General Public License v2.0 | 6 votes |
/** * Gets the raw data. The size of the byte array maybe larger than the actual length. */ public byte[] get() { if (data == null) { try { ByteArrayOutputStreamEx baos = new ByteArrayOutputStreamEx(1024); InputStream is = dataHandler.getDataSource().getInputStream(); baos.readFrom(is); is.close(); data = baos.getBuffer(); dataLen = baos.size(); } catch (IOException e) { // TODO: report the error to the unmarshaller dataLen = 0; // recover by assuming length-0 data } } return data; }