示例#1
0
        /// <summary>
        /// Return complete XML query for this type.
        /// </summary>
        /// <param name="id">ID of instance to get. May be empty to indicate all. Non-null.</param>
        /// <param name="parentId">Parent IDs. Closest first. May be empty if instances are accessed from the root. Non-null.</param>
        /// <returns>XML query. Never null.</returns>
        static String getQuery(String id, params String[] parentId)
        {
            if (id == null)
            {
                throw new ArgumentNullException("id cannot be null");
            }
            if (parentId == null)
            {
                throw new ArgumentNullException("parentId cannot be null");
            }

            String query = "<wells xmlns=\"" + WitsmlVersion.VERSION_1_3_1.getNamespace() + "\">" +
                           "  <well uid=\"" + id + "\">" +
                           "    <name/>" +
                           "    <nameLegal/>" +
                           "    <numLicense/>" +
                           "    <numGovt/>" +
                           "    <dTimLicense/>" +
                           "    <field/>" +
                           "    <country/>" +
                           "    <state/>" +
                           "    <county/>" +
                           "    <region/>" +
                           "    <district/>" +
                           "    <block/>" +
                           "    <timeZone/>" +
                           "    <operator/>" +
                           "    <operatorDiv/>" +
                           "    <pcInterest/>" + //BM added uom
                           "    <numAPI/>" +
                           "    <statusWell/>" +
                           "    <purposeWell/>" +
                           "    <fluidWell/>" +
                           "    <directionWell/>" +
                           "    <dTimSpud/>" +
                           "    <dTimPa/>" +
                           "    <wellheadElevation/>" +
                           "    <wellDatum/>" +
                           "    <groundElevation/>" +
                           "    <waterDepth uom=\"" + WitsmlServer.distUom + "\"/>" +
                           "    <wellLocation>" +
                           WitsmlLocation.getQuery() +
                           "    </wellLocation>" +
                           "    <referencePoint/>" +
                           "    <wellCRS/>" +
                           WitsmlCommonData.getQuery() +
                           "  </well>" +
                           "</wells>";

            return(query);
        }
        /**
         * Return complete XML query for this type.
         *
         * @return  XML query. Never null.
         */
        public static String getQuery()
        {
            String query = "<trajectoryStation uid = \"\">" +
                           "    <dTimStn/>" +
                           "    <typeTrajStation/>" +
                           "    <typeSurveyTool/>" +
                           "    <md uom=\"" + WitsmlServer.distUom + "\"/>" +
                           "    <tvd uom=\"" + WitsmlServer.distUom + "\"/>" +
                           "    <incl uom=\"rad\"/>" +
                           "    <azi uom=\"rad\"/>" +
                           "    <mtf uom=\"rad\"/>" +
                           "    <gtf uom=\"rad\"/>" +
                           "    <dispNs uom=\"" + WitsmlServer.distUom + "\"/>" +
                           "    <dispEw uom=\"" + WitsmlServer.distUom + "\"/>" +
                           "    <vertSect uom=\"" + WitsmlServer.distUom + "\"/>" +
                           "    <dls/>" +
                           "    <rateTurn/>" +
                           "    <rateBuild/>" +
                           "    <mdDelta uom=\"" + WitsmlServer.distUom + "\"/>" +
                           "    <tvdDelta uom=\"" + WitsmlServer.distUom + "\"/>" +
                           "    <modelToolError/>" +
                           "    <gravTotalUncert/>" +
                           "    <dipAngleUncert uom=\"rad\"/>" +
                           "    <magTotalUncert/>" +
                           "    <gravAccelCorUsed/>" +
                           "    <magXAxialCorUsed/>" +
                           "    <sagCorUsed/>" +
                           "    <magDrlstrCorUsed/>" +
                           "    <gravTotalFieldReference/>" +
                           "    <magTotalFieldReference/>" +
                           "    <magDipAngleReference uom=\"rad\"/>" +
                           "    <magModelUsed/>" +
                           "    <magModelValid/>" +
                           "    <geoModelUsed/>" +
                           "    <statusTrajStation/>" +
                           "    <rawData/>" +
                           "    <corUsed/>" +
                           "    <valid/>" +
                           "    <matrixCov/>" +
                           "    <location>" +
                           WitsmlLocation.getQuery() +
                           "    </location>" +
                           "    <sourceStation/>" +
                           WitsmlCommonData.getQuery() +
                           "</trajectoryStation>";

            return(query);
        }