예제 #1
0
        /**
         * Factory method for this type.
         *
         * @param server   Server the new instance lives within. Non-null.
         * @param parent   Parent instance. May be null.
         * @param element  XML element to create instance from. Non-null.
         * @return         New WITSML cement job instance. Never null.
         */
        static WitsmlObject newInstances(WitsmlServer server, WitsmlObject parent, XElement element)
        {
            //Debug.Assert(server != null : "server cannot be null";
            //Debug.Assert(element != null : "element cannot be null";

            String id       = element.Attribute("uidCementJob").Value;
            String parentId = element.Attribute("uidWellbore").Value;
            String name     = element.Element(element.Name.Namespace + "nameCementJob").Value.Trim(); //, element.getNamespace());

            WitsmlCementJob cementJob = new WitsmlCementJob(server, id, name, parent, parentId);

            cementJob.update(element);

            return(cementJob);
        }
예제 #2
0
        /**
         * Factory method for this type.
         *
         * @param server   Server the new instance lives within. Non-null.
         * @param parent   Parent instance. May be null.
         * @param element  XML element to create instance from. Non-null.
         * @return         New WITSML cement job instance. Never null.
         */
        static WitsmlObject newInstances(WitsmlServer server, WitsmlObject parent, XElement element)
        {
            //Debug.Assert(server != null : "server cannot be null";
            //Debug.Assert(element != null : "element cannot be null";

            String id = element.Attribute("uidCementJob").Value;
            String parentId = element.Attribute("uidWellbore").Value;
            String name = element.Element(element.Name.Namespace +"nameCementJob").Value.Trim(); //, element.getNamespace());

            WitsmlCementJob cementJob = new WitsmlCementJob(server, id, name, parent, parentId);
            cementJob.update(element);

            return cementJob;
        }