/** * Default constructor. */ public PDActionRemoteGoTo() { setSubType( SUB_TYPE ); }
/** * This will specify whether to open the destination document in a new window. * * @param value The flag value. */ public void setOpenInNewWindow(OpenMode value) { if (null == value) { getCOSObject().removeItem(COSName.NEW_WINDOW); return; } switch (value) { case USER_PREFERENCE: getCOSObject().removeItem(COSName.NEW_WINDOW); break; case SAME_WINDOW: getCOSObject().setBoolean(COSName.NEW_WINDOW, false); break; case NEW_WINDOW: getCOSObject().setBoolean(COSName.NEW_WINDOW, true); break; default: // shouldn't happen unless the enum type is changed break; } } }
} else if (action instanceof PDActionRemoteGoTo) { PDActionRemoteGoTo remoteGoTo = (PDActionRemoteGoTo)action; processDoc("", remoteGoTo.getFile(), attributes); } else if (action instanceof PDActionJavaScript) { PDActionJavaScript jsAction = (PDActionJavaScript)action;
break; case PDActionRemoteGoTo.SUB_TYPE: retval = new PDActionRemoteGoTo(action); break; case PDActionURI.SUB_TYPE:
} else if (action instanceof PDActionRemoteGoTo) { PDActionRemoteGoTo remoteGoTo = (PDActionRemoteGoTo)action; processDoc("", remoteGoTo.getFile(), attributes); } else if (action instanceof PDActionJavaScript) { PDActionJavaScript jsAction = (PDActionJavaScript)action;
retval = new PDActionRemoteGoTo( action );
} else if (action instanceof PDActionRemoteGoTo) { PDActionRemoteGoTo remoteGoTo = (PDActionRemoteGoTo)action; processDoc("", remoteGoTo.getFile(), attributes); } else if (action instanceof PDActionJavaScript) { PDActionJavaScript jsAction = (PDActionJavaScript)action;
/** * Default constructor. */ public PDActionRemoteGoTo() { setSubType( SUB_TYPE ); }
break; case PDActionRemoteGoTo.SUB_TYPE: retval = new PDActionRemoteGoTo(action); break; case PDActionURI.SUB_TYPE:
/** * This will specify whether to open the destination document in a new window, in the same * window, or behave in accordance with the current user preference. * * @return A flag specifying how to open the destination document. */ public OpenMode getOpenInNewWindow() { if (getCOSObject().getDictionaryObject(COSName.NEW_WINDOW) instanceof COSBoolean) { COSBoolean b = (COSBoolean) getCOSObject().getDictionaryObject(COSName.NEW_WINDOW); return b.getValue() ? OpenMode.NEW_WINDOW : OpenMode.SAME_WINDOW; } return OpenMode.USER_PREFERENCE; }
} else if (action instanceof PDActionRemoteGoTo) { PDActionRemoteGoTo remoteGoTo = (PDActionRemoteGoTo)action; processDoc("", remoteGoTo.getFile(), attributes); } else if (action instanceof PDActionJavaScript) { PDActionJavaScript jsAction = (PDActionJavaScript)action;
/** * Default constructor. */ public PDActionRemoteGoTo() { action = new COSDictionary(); setSubType( SUB_TYPE ); }
/** * This will specify whether to open the destination document in a new window, in the same * window, or behave in accordance with the current user preference. * * @return A flag specifying how to open the destination document. */ public OpenMode getOpenInNewWindow() { if (getCOSObject().getDictionaryObject(COSName.NEW_WINDOW) instanceof COSBoolean) { COSBoolean b = (COSBoolean) getCOSObject().getDictionaryObject(COSName.NEW_WINDOW); return b.getValue() ? OpenMode.NEW_WINDOW : OpenMode.SAME_WINDOW; } return OpenMode.USER_PREFERENCE; }
/** * This will specify whether to open the destination document in a new window. * * @param value The flag value. */ public void setOpenInNewWindow(OpenMode value) { if (null == value) { getCOSObject().removeItem(COSName.NEW_WINDOW); return; } switch (value) { case USER_PREFERENCE: getCOSObject().removeItem(COSName.NEW_WINDOW); break; case SAME_WINDOW: getCOSObject().setBoolean(COSName.NEW_WINDOW, false); break; case NEW_WINDOW: getCOSObject().setBoolean(COSName.NEW_WINDOW, true); break; default: // shouldn't happen unless the enum type is changed break; } } }