Пример #1
0
        private static FedoraA.ObjectFields[] GetAllContentObjects(NetworkCredential creds, string url)
        {
            FedoraA.FedoraAPIAService svc = new FedoraA.FedoraAPIAService();
            if (!String.IsNullOrEmpty(url))
            {
                svc.Url = url;
            }
            svc.Credentials = creds;

            FedoraA.FieldSearchQuery query = new FedoraA.FieldSearchQuery();
            query.Item = "pid~adl?";

            FedoraA.FieldSearchQuery fsq = new FedoraA.FieldSearchQuery();


            FedoraA.FieldSearchQueryConditions fsqConditions = new FedoraA.FieldSearchQueryConditions();

            FedoraA.Condition c = new FedoraA.Condition();

            FedoraA.Condition c2 = new FedoraA.Condition();
            c2.property  = "pid";
            c2.@operator = FedoraA.ComparisonOperator.has;
            c2.value     = "adl:*";

            fsqConditions.condition = new FedoraA.Condition[] { c2 };

            fsq.Item = fsqConditions;
            var results = svc.findObjects(new String[] { "pid", "label" }, "10000", fsq);

            return(results.resultList);
        }
Пример #2
0
        private static FedoraA.ObjectFields[] GetAllContentObjects(NetworkCredential creds, string url)
        {
            FedoraA.FedoraAPIAService svc = new FedoraA.FedoraAPIAService();
            if (!String.IsNullOrEmpty(url))
            {
                svc.Url = url;
            }
            svc.Credentials = creds;

            FedoraA.FieldSearchQuery query = new FedoraA.FieldSearchQuery();
            query.Item = "pid~adl?";

            FedoraA.FieldSearchQuery fsq = new FedoraA.FieldSearchQuery();

            FedoraA.FieldSearchQueryConditions fsqConditions = new FedoraA.FieldSearchQueryConditions();

            FedoraA.Condition c = new FedoraA.Condition();

            FedoraA.Condition c2 = new FedoraA.Condition();
            c2.property = "pid";
            c2.@operator = FedoraA.ComparisonOperator.has;
            c2.value = "adl:*";

            fsqConditions.condition = new FedoraA.Condition[] { c2 };

            fsq.Item = fsqConditions;
            var results = svc.findObjects(new String[] { "pid", "label" }, "10000", fsq);

            return (results.resultList);
        }