/** * Schedules this file to be automatically deleted when the VM terminates normally. * * <p><i>Note that on Android, the application lifecycle does not include VM termination, * so calling this method will not ensure that files are deleted</i>. Instead, you should * use the most appropriate out of: * <ul> * <li>Use a {@code finally} clause to manually invoke {@link #delete}. * <li>Maintain your own set of files to delete, and process it at an appropriate point * in your application's lifecycle. * <li>Use the Unix trick of deleting the file as soon as all readers and writers have * opened it. No new readers/writers will be able to access the file, but all existing * ones will still have access until the last one closes the file. * </ul> */ public void deleteOnExit() { DeleteOnExit.getInstance().addFile(getAbsolutePath()); }
/** * Returns our singleton instance, creating it if necessary. */ public static synchronized DeleteOnExit getInstance() { if (instance == null) { instance = new DeleteOnExit(); Runtime.getRuntime().addShutdownHook(instance); } return instance; }
@Override public IIOMetadata convertStreamMetadata(IIOMetadata arg0, ImageWriteParam arg1) throws NotImplementedException { // TODO: implement throw new NotImplementedException(); }
public static String convertFromUTF8(byte[] buf, int offset, int utfSize) throws UTFDataFormatException { return convertUTF8WithBuf(buf, new char[utfSize], offset, utfSize); }
/** * '%' and two following hex digit characters are converted to the * equivalent byte value. All other characters are passed through * unmodified. e.g. "ABC %24%25" -> "ABC $%" * * @param s * java.lang.String The encoded string. * @return java.lang.String The decoded version. */ public static String decode(String s, boolean convertPlus) { return decode(s, convertPlus, null); }
public static String toUTF8String(byte[] bytes) { return toUTF8String(bytes, 0, bytes.length); }
/** * Returns our singleton instance, creating it if necessary. */ public static synchronized DeleteOnExit getInstance() { if (instance == null) { instance = new DeleteOnExit(); Runtime.getRuntime().addShutdownHook(instance); } return instance; }
@Override public IIOMetadata getDefaultStreamMetadata(ImageWriteParam arg0) throws NotImplementedException { // TODO: implement throw new NotImplementedException(); }
public String readUTF() throws IOException { ByteOrder byteOrder = getByteOrder(); setByteOrder(ByteOrder.BIG_ENDIAN); final int size = readUnsignedShort(); final byte[] buf = new byte[size]; final char[] out = new char[size]; readFully(buf, 0, size); setByteOrder(byteOrder); //return new DataInputStream(new ByteArrayInputStream(buff)).readUTF(); return Util.convertUTF8WithBuf(buf, out, 0, size); }
/** * Returns our singleton instance, creating it if necessary. */ public static synchronized DeleteOnExit getInstance() { if (instance == null) { instance = new DeleteOnExit(); Runtime.getRuntime().addShutdownHook(instance); } return instance; }
/** * Returns a justification information for the glyph with specified glyph * index. * @param glyphIndex index of a glyph which GlyphJustificationInfo is to be * received * @return a GlyphJustificationInfo object that contains glyph justification * properties of the specified glyph */ @Override public GlyphJustificationInfo getGlyphJustificationInfo(int glyphIndex) { throw new NotImplementedException(); }
/** * Returns our singleton instance, creating it if necessary. */ public static synchronized DeleteOnExit getInstance() { if (instance == null) { instance = new DeleteOnExit(); Runtime.getRuntime().addShutdownHook(instance); } return instance; }
@Override public IIOMetadata convertImageMetadata(IIOMetadata arg0, ImageTypeSpecifier arg1, ImageWriteParam arg2) throws NotImplementedException { // TODO: implement throw new NotImplementedException(); }
/** * Returns our singleton instance, creating it if necessary. */ public static synchronized DeleteOnExit getInstance() { if (instance == null) { instance = new DeleteOnExit(); Runtime.getRuntime().addShutdownHook(instance); } return instance; }
public static Iterator<ImageTranscoder> getImageTranscoders(ImageReader reader, ImageWriter writer) throws NotImplementedException { // TODO: implement throw new NotImplementedException(); }
@Override public IIOMetadata convertImageMetadata(IIOMetadata iioMetadata, ImageTypeSpecifier imageTypeSpecifier, ImageWriteParam imageWriteParam) throws NotImplementedException { // TODO: implement throw new NotImplementedException(); }
@Override public IIOMetadata getDefaultImageMetadata(ImageTypeSpecifier arg0, ImageWriteParam arg1) throws NotImplementedException { // TODO: implement throw new NotImplementedException(); }
@Override public IIOMetadata convertStreamMetadata(IIOMetadata iioMetadata, ImageWriteParam imageWriteParam) throws NotImplementedException { // TODO: implement throw new NotImplementedException(); }
public IIOMetadata getDefaultImageMetadata(ImageTypeSpecifier imageTypeSpecifier, ImageWriteParam imageWriteParam) throws NotImplementedException { // TODO: implement throw new NotImplementedException(); }
public IIOMetadata getDefaultStreamMetadata(ImageWriteParam imageWriteParam) throws NotImplementedException { // TODO: implement throw new NotImplementedException(); }