/** * Returns a <CODE>PdfObject</CODE> as a <CODE>PdfBoolean</CODE>, * resolving indirect references. * * The object corresponding to the specified index is retrieved and * resolved to a direct object. * If it is a <CODE>PdfBoolean</CODE>, it is cast down and returned as * such. Otherwise <CODE>null</CODE> is returned. * * @param idx The index of the <CODE>PdfObject</CODE> to be returned * @return the corresponding <CODE>PdfBoolean</CODE> object, * or <CODE>null</CODE> */ public PdfBoolean getAsBoolean(final int idx) { PdfBoolean bool = null; PdfObject orig = getDirectObject(idx); if (orig != null && orig.isBoolean()) bool = (PdfBoolean) orig; return bool; }
/** * Returns a <CODE>PdfObject</CODE> as a <CODE>PdfBoolean</CODE>, * resolving indirect references. * * The object associated with the <CODE>PdfName</CODE> given is retrieved * and resolved to a direct object. * If it is a <CODE>PdfBoolean</CODE>, it is cast down and returned as such. * Otherwise <CODE>null</CODE> is returned. * * @param key A <CODE>PdfName</CODE> * @return the associated <CODE>PdfBoolean</CODE> object, * or <CODE>null</CODE> */ public PdfBoolean getAsBoolean(final PdfName key) { PdfBoolean bool = null; PdfObject orig = getDirectObject(key); if (orig != null && orig.isBoolean()) bool = (PdfBoolean)orig; return bool; }
/** * Returns a <CODE>PdfObject</CODE> as a <CODE>PdfBoolean</CODE>, * resolving indirect references. * * The object corresponding to the specified index is retrieved and * resolved to a direct object. * If it is a <CODE>PdfBoolean</CODE>, it is cast down and returned as * such. Otherwise <CODE>null</CODE> is returned. * * @param idx The index of the <CODE>PdfObject</CODE> to be returned * @return the corresponding <CODE>PdfBoolean</CODE> object, * or <CODE>null</CODE> */ public PdfBoolean getAsBoolean(final int idx) { PdfBoolean bool = null; PdfObject orig = getDirectObject(idx); if (orig != null && orig.isBoolean()) bool = (PdfBoolean) orig; return bool; }
/** * Returns a <CODE>PdfObject</CODE> as a <CODE>PdfBoolean</CODE>, * resolving indirect references. * * The object associated with the <CODE>PdfName</CODE> given is retrieved * and resolved to a direct object. * If it is a <CODE>PdfBoolean</CODE>, it is cast down and returned as such. * Otherwise <CODE>null</CODE> is returned. * * @param key A <CODE>PdfName</CODE> * @return the associated <CODE>PdfBoolean</CODE> object, * or <CODE>null</CODE> */ public PdfBoolean getAsBoolean(final PdfName key) { PdfBoolean bool = null; PdfObject orig = getDirectObject(key); if (orig != null && orig.isBoolean()) bool = (PdfBoolean)orig; return bool; }
if (!compareStringsExtended((PdfString) outDirectObj, (PdfString) cmpDirectObj, currentPath, compareResult)) return false; } else if (cmpDirectObj.isBoolean()) { if (!compareBooleansExtended((PdfBoolean) outDirectObj, (PdfBoolean) cmpDirectObj, currentPath, compareResult)) return false;
if (!compareStringsExtended((PdfString) outDirectObj, (PdfString) cmpDirectObj, currentPath, compareResult)) return false; } else if (cmpDirectObj.isBoolean()) { if (!compareBooleansExtended((PdfBoolean) outDirectObj, (PdfBoolean) cmpDirectObj, currentPath, compareResult)) return false;
return false; if (value1.isBoolean()) { if (value1 == value2) return true;
return false; if (value1.isBoolean()) { if (value1 == value2) return true;