Package org.oclc.oomRef.descriptors

Examples of org.oclc.oomRef.descriptors.ByValueMetadataImpl


        Object[] svcData = (Object[]) co.getServiceTypes()[0].getDescriptors();
        if (svcData != null && svcData.length > 0) {
            for (int i = 0; i < svcData.length; i++) {
                Object tmp = svcData[i];
                if (tmp.getClass().getSimpleName().equals("ByValueMetadataImpl")) {
                    ByValueMetadataImpl kev = ((ByValueMetadataImpl) tmp);
                    if (kev.getFieldMap().size() > 0) {
                        if (kev.getFieldMap().containsKey("svc.region")
                                && ((String[]) kev.getFieldMap().get(
                                        "svc.region"))[0] != "")
                            map.put("region", ((String[]) kev.getFieldMap()
                                    .get("svc.region"))[0]);
                        if (kev.getFieldMap().containsKey("svc.format")
                                && ((String[]) kev.getFieldMap().get(
                                        "svc.format"))[0] != "")
                            map.put("format", ((String[]) kev.getFieldMap()
                                    .get("svc.format"))[0]);
                        if (kev.getFieldMap().containsKey("svc.level")
                                && ((String[]) kev.getFieldMap().get(
                                        "svc.level"))[0] != "")
                            map.put("level", ((String[]) kev.getFieldMap()
                                    .get("svc.level"))[0]);
                        if (kev.getFieldMap().containsKey("svc.rotate")
                                && ((String[]) kev.getFieldMap().get(
                                        "svc.rotate"))[0] != "")
                            map.put("rotate", ((String[]) kev.getFieldMap()
                                    .get("svc.rotate"))[0]);
                        if (kev.getFieldMap().containsKey("svc.scale")
                                && ((String[]) kev.getFieldMap().get(
                                        "svc.scale"))[0] != "")
                            map.put("scale", ((String[]) kev.getFieldMap()
                                    .get("svc.scale"))[0]);
                        if (kev.getFieldMap().containsKey("svc.clayer")
                                && ((String[]) kev.getFieldMap().get(
                                        "svc.clayer"))[0] != "")
                            map.put("clayer", ((String[]) kev.getFieldMap()
                                    .get("svc.clayer"))[0]);
                    }
                }
            }
        }
View Full Code Here


                    for (int i = 0; i < values.length; ++i) {
                        referentDescriptors.add(values[i]);
                    }
                } else if ("rft_val_fmt".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        ByValueMetadataImpl bvm = new ByValueMetadataImpl(new URI(values[i]), "rft.", entrySet);
                        referentDescriptors.add(bvm);
                    }
                } else if ("rft_ref_fmt".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        String[] rft_refs = req.getParameterValues("rft_ref");
                        for (int j = 0; j < rft_refs.length; ++j) {
                            ByReferenceMetadataImpl brm =
                                    new ByReferenceMetadataImpl(new URI(values[i]), new URL(rft_refs[j]));
                            referentDescriptors.add(brm);
                        }
                    }
                } else if ("req_id".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        requesterDescriptors.add(new URI(values[i]));
                    }
                } else if ("req_dat".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        requesterDescriptors.add(values[i]);
                    }
                } else if ("req_val_fmt".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        ByValueMetadataImpl bvm = new ByValueMetadataImpl(new URI(values[i]), "req.", entrySet);
                        requesterDescriptors.add(bvm);
                    }
                } else if ("req_ref_fmt".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        String[] req_refs = req.getParameterValues("req_ref");
                        for (int j = 0; j < req_refs.length; ++j) {
                            ByReferenceMetadataImpl brm =
                                    new ByReferenceMetadataImpl(new URI(values[i]), new URL(req_refs[j]));
                            requesterDescriptors.add(brm);
                        }
                    }
                } else if ("rfe_id".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        referringEntityDescriptors.add(new URI(values[i]));
                    }
                } else if ("rfe_dat".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        referringEntityDescriptors.add(values[i]);
                    }
                } else if ("rfe_val_fmt".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        ByValueMetadataImpl bvm = new ByValueMetadataImpl(new URI(values[i]), "rfe.", entrySet);
                        referringEntityDescriptors.add(bvm);
                    }
                } else if ("rfe_ref_fmt".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        String[] rfe_refs = req.getParameterValues("rfe_ref");
                        for (int j = 0; j < rfe_refs.length; ++j) {
                            ByReferenceMetadataImpl brm =
                                    new ByReferenceMetadataImpl(new URI(values[i]), new URL(rfe_refs[j]));
                            referringEntityDescriptors.add(brm);
                        }
                    }
                } else if ("rfr_id".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        referrerDescriptors.add(new URI(values[i]));
                    }
                } else if ("rfr_dat".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        referrerDescriptors.add(values[i]);
                    }
                } else if ("rfr_val_fmt".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        ByValueMetadataImpl bvm = new ByValueMetadataImpl(new URI(values[i]), "rfr.", entrySet);
                        referrerDescriptors.add(bvm);
                    }
                } else if ("rfr_ref_fmt".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        String[] rfr_refs = req.getParameterValues("rfr_ref");
                        for (int j = 0; j < rfr_refs.length; ++j) {
                            ByReferenceMetadataImpl brm =
                                    new ByReferenceMetadataImpl(new URI(values[i]), new URL(rfr_refs[j]));
                            referrerDescriptors.add(brm);
                        }
                    }
                } else if ("res_id".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        resolverDescriptors.add(new URI(values[i]));
                    }
                } else if ("res_dat".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        resolverDescriptors.add(values[i]);
                    }
                } else if ("res_val_fmt".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        ByValueMetadataImpl bvm = new ByValueMetadataImpl(new URI(values[i]), "res.", entrySet);
                        resolverDescriptors.add(bvm);
                    }
                } else if ("res_ref_fmt".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        String[] res_refs = req.getParameterValues("res_ref");
                        for (int j = 0; j < res_refs.length; ++j) {
                            ByReferenceMetadataImpl brm =
                                    new ByReferenceMetadataImpl(new URI(values[i]), new URL(res_refs[j]));
                            resolverDescriptors.add(brm);
                        }
                    }
                } else if ("svc_id".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        URI uri = new URI(values[i]);

                        serviceTypeDescriptors.add(uri);

                        // Throw in the corresponding Java class while we're
                        // here
                        Service service = (Service) openURLConfig.getService(uri);
                        serviceTypeDescriptors.add(service);
                    }
                } else if ("svc_dat".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        serviceTypeDescriptors.add(values[i]);
                    }
                } else if ("svc_val_fmt".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        ByValueMetadataImpl bvm = new ByValueMetadataImpl(new URI(values[i]), "svc.", entrySet);
                        serviceTypeDescriptors.add(bvm);
                    }
                } else if ("svc_ref_fmt".equals(key)) {
                    for (int i = 0; i < values.length; ++i) {
                        String[] svc_refs = req.getParameterValues("svc_ref");
View Full Code Here

        final Object[] svcData = co.getServiceTypes()[0].getDescriptors();
        if (svcData != null && svcData.length > 0) {
            for (int i = 0; i < svcData.length; i++) {
                final Object tmp = svcData[i];
                if (tmp.getClass().getSimpleName().equals("ByValueMetadataImpl")) {
                    final ByValueMetadataImpl kev = ((ByValueMetadataImpl) tmp);
                    if (kev.getFieldMap().size() > 0) {
                        if (kev.getFieldMap().containsKey("svc.region") &&
                                ((String[]) kev.getFieldMap().get("svc.region"))[0] != "") {
                            map.put("region", ((String[]) kev.getFieldMap().get("svc.region"))[0]);
                        }
                        if (kev.getFieldMap().containsKey("svc.format") &&
                                ((String[]) kev.getFieldMap().get("svc.format"))[0] != "") {
                            map.put("format", ((String[]) kev.getFieldMap().get("svc.format"))[0]);
                        }
                        if (kev.getFieldMap().containsKey("svc.level") &&
                                ((String[]) kev.getFieldMap().get("svc.level"))[0] != "") {
                            map.put("level", ((String[]) kev.getFieldMap().get("svc.level"))[0]);
                        }
                        if (kev.getFieldMap().containsKey("svc.rotate") &&
                                ((String[]) kev.getFieldMap().get("svc.rotate"))[0] != "") {
                            map.put("rotate", ((String[]) kev.getFieldMap().get("svc.rotate"))[0]);
                        }
                        if (kev.getFieldMap().containsKey("svc.scale") &&
                                ((String[]) kev.getFieldMap().get("svc.scale"))[0] != "") {
                            map.put("scale", ((String[]) kev.getFieldMap().get("svc.scale"))[0]);
                        }
                        if (kev.getFieldMap().containsKey("svc.clayer") &&
                                ((String[]) kev.getFieldMap().get("svc.clayer"))[0] != "") {
                            map.put("clayer", ((String[]) kev.getFieldMap().get("svc.clayer"))[0]);
                        }
                    }
                }
            }
        }
View Full Code Here

    /**
     * Creates a ByValueMetadata object.
     */
    public ByValueMetadata byValueMetadataFactory(URI val_fmt, String prefix, Set entrySet) {
        return new ByValueMetadataImpl(val_fmt, prefix, entrySet);
    }
View Full Code Here

TOP

Related Classes of org.oclc.oomRef.descriptors.ByValueMetadataImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.