コード例 #1
0
        public string CreateRequestBody(int startPosition)
        {
            var getRecords = new GetRecordsType();

            getRecords.resultType    = ResultType1.results;
            getRecords.startPosition = startPosition.ToString(CultureInfo.InvariantCulture);

            var query           = new QueryType();
            var queryConstraint = new QueryConstraintType();

            queryConstraint.version = "1.1.0";
            queryConstraint.Item    = CreateFilterForNorwayDigital();
            query.Constraint        = queryConstraint;

            getRecords.Item = query;

            return(SerializeUtil.SerializeToString(getRecords));
        }
コード例 #2
0
        public GetRecordsType GetRecordsWithFilter(object[] filters, ItemsChoiceType23[] filterNames, int startPosition = 1, int limit = 20, bool sortByTitle = false, string outputSchema = "csw:Record")
        {
            var getRecords = new GetRecordsType();

            getRecords.resultType    = ResultType1.results;
            getRecords.startPosition = startPosition.ToString();
            getRecords.maxRecords    = limit.ToString();
            getRecords.outputSchema  = outputSchema;

            var query = new QueryType();

            query.typeNames = new[] { new XmlQualifiedName("Record", "http://www.opengis.net/cat/csw/2.0.2") };
            var queryConstraint = new QueryConstraintType();

            queryConstraint.version = "1.1.0";
            queryConstraint.Item    = new FilterType
            {
                Items            = filters,
                ItemsElementName = filterNames
            };
            query.Constraint = queryConstraint;
            query.Items      = new object[] { new ElementSetNameType {
                                                  Value = ElementSetType.full
                                              } };

            if (sortByTitle)
            {
                query.SortBy = new SortPropertyType[]
                {
                    new SortPropertyType {
                        PropertyName = new PropertyNameType {
                            Text = new string[] { "Title" }
                        },
                        SortOrder = SortOrderType.ASC
                    }
                };
            }
            getRecords.Item = query;

            return(getRecords);
        }
コード例 #3
0
 public PNAssertionReachabilityWith(DefinitionRef processDef, string reachableState, QueryConstraintType cont, Expression constraintCondition)
     : base(reachableState, cont, constraintCondition)
 {
     Process = processDef;
 }
コード例 #4
0
 public KWSNAssertionReachabilityWith(DefinitionRef processDef, string reachableState, QueryConstraintType cont, Expression constraintCondition)
     : base(reachableState, cont, constraintCondition)
 {
     Process = processDef;
 }
コード例 #5
0
 protected AssertionReachabilityWith(string reachableState, QueryConstraintType cont, Expression constraintCondition) : base(reachableState)
 {
     Contraint           = cont;
     ConstraintCondition = constraintCondition;
 }
コード例 #6
0
 protected AssertionReachabilityWith(string reachableState, QueryConstraintType cont, Expression constraintCondition)
     : base(reachableState)
 {
     Contraint = cont;
     ConstraintCondition = constraintCondition;
 }