Exemple #1
0
        ///
        ///	 <summary> * Appends new FileSpec(RasterFileLocation) element to the end of 'this'
        ///	 *  </summary>
        ///	 * <returns> JDFFileSpec: newly created child RasterFileLocation element </returns>
        ///
        public virtual JDFFileSpec appendRasterFileLocation()
        {
            JDFFileSpec res = appendFileSpec();

            res.setResourceUsage("RasterFileLocation");
            return(res);
        }
Exemple #2
0
        internal virtual JDFFileSpec appendTargetProfile()
        {
            JDFFileSpec res = appendFileSpec();

            res.setResourceUsage("TargetProfile");

            return(res);
        }
Exemple #3
0
        public virtual JDFFileSpec appendColorProfile()
        {
            JDFFileSpec res = appendFileSpec();

            res.setResourceUsage("ColorProfile");

            return(res);
        }
Exemple #4
0
        public virtual JDFFileSpec getCreateTargetProfile()
        {
            JDFFileSpec res = getTargetProfile();

            if (res == null)
            {
                res = appendTargetProfile();
            }
            return(res);
        }
Exemple #5
0
        public virtual JDFFileSpec getCreateColorProfile()
        {
            JDFFileSpec res = getColorProfile();

            if (res == null)
            {
                res = appendColorProfile();
            }
            return(res);
        }
Exemple #6
0
        ///
        ///	 <summary> * Gets of 'this' child FileSpec(RasterFileLocation) element, optionally
        ///	 * creates it, if it doesn't exist.
        ///	 *  </summary>
        ///	 * <returns> JDFFileSpec: the matching RasterFileLocation element </returns>
        ///
        public virtual JDFFileSpec getCreateRasterFileLocation()
        {
            JDFFileSpec res = getRasterFileLocation();

            if (res == null)
            {
                res = appendRasterFileLocation();
            }

            return(res);
        }
Exemple #7
0
        public virtual void testAbstractProfile()
        {
            JDFDoc doc = new JDFDoc("JDF");

            doc.setOriginalFileName("JDF.jdf");
            JDFNode n = doc.getJDFRoot();

            n.setType(EnumType.ColorSpaceConversion);
            JDFColorSpaceConversionParams cscp = (JDFColorSpaceConversionParams)n.addResource(ElementName.COLORSPACECONVERSIONPARAMS, null, EnumUsage.Input, null, null, null, null);
            JDFFileSpec fs0 = cscp.appendFinalTargetDevice();
            JDFFileSpec fs1 = cscp.getFinalTargetDevice();

            Assert.AreEqual(fs1, fs0);
            fs0 = (JDFFileSpec)fs0.makeRootResource(null, null, true);
            fs1 = cscp.getFinalTargetDevice();
            Assert.AreEqual(fs1, fs0);
        }
Exemple #8
0
        ///
        ///	 <summary> * Gets of 'this' an existing child FileSpec(RasterFileLocation) element
        ///	 *  </summary>
        ///	 * <returns> JDFFileSpec: the matching RasterFileLocation element or null if
        ///	 *         nothing was found </returns>
        ///
        public virtual JDFFileSpec getRasterFileLocation()
        {
            VElement v   = getChildElementVector(ElementName.FILESPEC, null, null, true, 0, false);
            int      siz = v.Count;

            for (int i = 0; i < siz; i++)
            {
                JDFFileSpec res = (JDFFileSpec)v[i];
                if (res.hasAttribute(AttributeName.RESOURCEUSAGE))
                {
                    if (res.getResourceUsage().Equals("RasterFileLocation"))
                    {
                        return(res);
                    }
                }
            }
            return(null);
        }