Refine search
public OutputStreamXMLOutput(@WillCloseWhenClosed Writer writer, String stylesheet) { this.out = writer; this.nestingLevel = 0; this.newLine = true; this.stylesheet = stylesheet; } @Override
/** * Construct a new CSV writer. * * @param w The underlying writer to output to. * @param l The table layout, or {@code null} if the table has no headers. * @throws IOException if there is an error writing the column headers. */ public CSVWriter(@WillCloseWhenClosed @Nonnull Writer w, @Nullable TableLayout l) throws IOException { Preconditions.checkNotNull(w, "writer"); layout = l; if (w instanceof BufferedWriter) { writer = (BufferedWriter) w; } else { writer = new BufferedWriter(w); } if (layout != null) { writeRow(layout.getColumns().toArray(new Object[l.getColumnCount()])); } }
/** * Constructs a new counting input stream. * * @param in the decorated input stream. */ @CreatesObligation @edu.umd.cs.findbugs.annotations.SuppressWarnings("OBL_UNSATISFIED_OBLIGATION") CountingInputStream(@Nullable @WillCloseWhenClosed InputStream in) { super(in); }
/** * Constructs a ZIP output stream which decorates the given output stream * using the {@code "UTF-8"} charset. * * @param out The output stream to write the ZIP file to. */ @CreatesObligation @edu.umd.cs.findbugs.annotations.SuppressWarnings("OBL_UNSATISFIED_OBLIGATION") public ZipOutputStream(@WillCloseWhenClosed OutputStream out) { super(out, null, DEFAULT_PARAM); }
/** * Creates a formatter with default settings. * * @param aWriter * Writer to use * @param aSettings * The settings to be used. */ public JSFormatter (@Nonnull @WillCloseWhenClosed final Writer aWriter, @Nullable final IJSWriterSettings aSettings) { this (aWriter instanceof PrintWriter ? (PrintWriter) aWriter : new PrintWriter (aWriter), aSettings); }
/** * Creates a read only file for transparent random read access to an * encrypted file. * The client must call {@link #init(SeekableBlockCipher, long, long)} * before it can actually read anything! * * @param rof A read-only file. * This may be {@code null}, but must be properly initialized * <em>before</em> a call to {@link #init}. */ @CreatesObligation @edu.umd.cs.findbugs.annotations.SuppressWarnings("OBL_UNSATISFIED_OBLIGATION") protected CipherReadOnlyFile(@Nullable @WillCloseWhenClosed ReadOnlyFile rof) { super(rof); }
/** * Constructs a new ODF output shop. * * @param output the decorated output shop. * @param pool the pool for buffering entry data. */ @CreatesObligation @edu.umd.cs.findbugs.annotations.SuppressWarnings("OBL_UNSATISFIED_OBLIGATION") public OdfOutputShop(@WillCloseWhenClosed ZipOutputShop output, IOPool<?> pool) { super(output, pool); }
/** * Creates a formatter with default settings. * * @param aWriter * Writer to use * @param aSettings * The settings to be used. */ public JSFormatter (@Nonnull @WillCloseWhenClosed final Writer aWriter, @Nullable final IJSWriterSettings aSettings) { this (aWriter instanceof PrintWriter ? (PrintWriter) aWriter : new PrintWriter (aWriter), aSettings); }
@CreatesObligation @edu.umd.cs.findbugs.annotations.SuppressWarnings("OBL_UNSATISFIED_OBLIGATION") RaesOutputStream( @CheckForNull @WillCloseWhenClosed OutputStream out, @CheckForNull BufferedBlockCipher cipher) { super(out, cipher); }
public ZipSourceRepository(@WillCloseWhenClosed ZipFile zipFile) { this.zipFile = zipFile; }
/** * Creates a JFormatter. * * @param aPrintWriter * PrintWriter to use. * @param aSettings * The settings to be used. */ public JSFormatter (@Nonnull @WillCloseWhenClosed final PrintWriter aPrintWriter, @Nullable final IJSWriterSettings aSettings) { m_aPW = ValueEnforcer.notNull (aPrintWriter, "PrintWriter"); m_aSettings = JSWriterSettings.createCloneOnDemand (aSettings); }
@CreatesObligation @edu.umd.cs.findbugs.annotations.SuppressWarnings("OBL_UNSATISFIED_OBLIGATION") RaesReadOnlyFile(@CheckForNull @WillCloseWhenClosed ReadOnlyFile rof) { super(rof); }
/** * Constructor. * * @param writer * Writer to write XML output to */ @SuppressFBWarnings("OBL_UNSATISFIED_OBLIGATION") public OutputStreamXMLOutput(@WillCloseWhenClosed Writer writer) { this(writer, null); } /**
/** * Creates a JFormatter. * * @param aPrintWriter * PrintWriter to use. * @param aSettings * The settings to be used. */ public JSFormatter (@Nonnull @WillCloseWhenClosed final PrintWriter aPrintWriter, @Nullable final IJSWriterSettings aSettings) { m_aPW = ValueEnforcer.notNull (aPrintWriter, "PrintWriter"); m_aSettings = JSWriterSettings.createCloneOnDemand (aSettings); }
@CreatesObligation @edu.umd.cs.findbugs.annotations.SuppressWarnings("OBL_UNSATISFIED_OBLIGATION") DummyByteInputStream(@WillCloseWhenClosed ReadOnlyFile rof) { super(rof); }
/** * Constructor. * * @param os * OutputStream to write XML output to */ @SuppressFBWarnings("OBL_UNSATISFIED_OBLIGATION") public OutputStreamXMLOutput(@WillCloseWhenClosed OutputStream os) { this(os, null); } /**
/** * Queries the database with the given query, the * query should be a <code>SELECT</code> query. * * @param query The query to run. * @return the current result as a <code>ResultSet</code> object or * <code>null</code> if the result is an update count or there are no more results * @throws SQLException if a database access error occurs or this method is called on a * closed <code>Statement</code> */ @Nullable @WillCloseWhenClosed public final ResultSet query(QueryBuilder query) throws SQLException { return query(query.toSQL()); }
/** * Constructs a ZIP output stream which decorates the given output stream * and appends to the given ZIP file. * * @param out The output stream to write the ZIP file to. * If {@code appendee} is not {@code null}, then this must be set * up so that it appends to the same ZIP file from which * {@code appendee} is reading. * @param appendee the ZIP file to append to. * This may already be closed. */ @CreatesObligation @edu.umd.cs.findbugs.annotations.SuppressWarnings("OBL_UNSATISFIED_OBLIGATION") public ZipOutputStream(@WillCloseWhenClosed OutputStream out, ZipFile appendee) { super(out, appendee, DEFAULT_PARAM); if (null == appendee) throw new NullPointerException(); }
public void setBase(@WillCloseWhenClosed SourceRepository base) { this.base = base; ready.countDown(); }
/** * Construct a new CSV writer. * * @param w The underlying writer to output to. * @param l The table layout, or {@code null} if the table has no headers. * @throws IOException if there is an error writing the column headers. */ public CSVWriter(@WillCloseWhenClosed @Nonnull Writer w, @Nullable TableLayout l) throws IOException { Preconditions.checkNotNull(w, "writer"); layout = l; if (w instanceof BufferedWriter) { writer = (BufferedWriter) w; } else { writer = new BufferedWriter(w); } if (layout != null) { writeRow(layout.getColumns().toArray(new Object[l.getColumnCount()])); } }