Examples of AttrValue


Examples of org.jzkit.search.util.QueryModel.Internal.AttrValue

           if(Log.isDebugEnabled(Geonet.SRU_SEARCH)) Log.debug(Geonet.SRU_SEARCH,"Processing attrplustermnode:"+aptn);
               // Look up conversion information for source node

               // set default relation context set
               if ( aptn.getRelation() != null ) {
                       AttrValue relation = (AttrValue)aptn.getRelation();

                       if ( relation !=null && (relation.getNamespaceIdentifier() == null || force_def  )) {
                               relation.setNamespaceIdentifier(this.default_rel_namespace);
                           if(Log.isDebugEnabled(Geonet.SRU_SEARCH))
                               Log.debug(Geonet.SRU_SEARCH,"Processing relation :"+relation);
                       }
               }

               // set default attribute context set

               Object ap_node = aptn.getAccessPoint();
               if ( ap_node != null ) {
                       AttrValue qualifier = (AttrValue)ap_node;

                       if ( qualifier != null && ( qualifier.getNamespaceIdentifier() == null || force_def )) {
                               qualifier.setNamespaceIdentifier(this.default_attr_namespace);
                           if(Log.isDebugEnabled(Geonet.SRU_SEARCH))
                               Log.debug(Geonet.SRU_SEARCH,"Processing AccessPoint :"+qualifier);
                      
                       }

                       // FIX incorrect behavior of very old CQL (0.0.7) library
                       if qualifier != null &&
                                       qualifier.getNamespaceIdentifier().equalsIgnoreCase("srw") &&
                                       qualifier.getValue().equalsIgnoreCase("serverChoice")) {
                           if(Log.isDebugEnabled(Geonet.SRU_SEARCH))
                               Log.debug(Geonet.SRU_SEARCH,"Setting srw context set to cql for serverChoice");
                               qualifier.setNamespaceIdentifier("cql");
                       }
                      
                      
               }
              
               // set default structure context set
               if ( aptn.getStructure() != null ) {
                       AttrValue structure = (AttrValue)aptn.getStructure();

                       if ( structure !=null && (structure.getNamespaceIdentifier() == null || force_def  )) {
                               structure.setNamespaceIdentifier(this.default_struct_namespace);
                           if(Log.isDebugEnabled(Geonet.SRU_SEARCH))
                               Log.debug(Geonet.SRU_SEARCH,"Processing structure :"+structure);
                       }
               }
              
View Full Code Here

Examples of org.jzkit.search.util.QueryModel.Internal.AttrValue

                ssd.getValidAttrs().put(prop_name,valid_attr_set);
              }

              for ( java.util.Iterator i2 = prop_value.iterator(); i2.hasNext(); ) {
                String valid_attr = (String) i2.next();
                valid_attr_set.getAttrs().add(new AttrValue(valid_attr));
              }
            }
          }
        }
        else {
          log.info("No archetypes in SSD DTO");
        }

        if ( svc.valid_indexes != null ) {
          for ( java.util.Iterator i = svc.valid_indexes.entrySet().iterator(); i.hasNext(); ) {
            Map.Entry e = (Map.Entry) i.next();
            if ( e != null ) {
              String prop_name = e.getKey().toString();
              String prop_value = e.getValue().toString();
              ssd.getServiceSpecificTranslations().put(prop_name,new AttrValue(prop_value));
            }
          }
        }
        else {
          log.info("No archetypes in SSD DTO");
View Full Code Here

Examples of org.jzkit.search.util.QueryModel.Internal.AttrValue

               java.util.Set valid_attrs_of_type = ss_dto.valid_indexes.get(idx.getAttribute("type"));
               if ( valid_attrs_of_type == null ) {
                 valid_attrs_of_type = new java.util.HashSet();
                 ss_dto.valid_indexes.put(idx.getAttribute("type"),valid_attrs_of_type);
               }
               AttrValue valid_av = new AttrValue(idx.getAttribute("context"),val_node.getNodeValue());
               valid_attrs_of_type.add(valid_av);
               log.debug("Added valid attr of type "+idx.getAttribute("type")+" : "+valid_av);
             }
             else {
               log.error("Coll element was null");
View Full Code Here

Examples of org.jzkit.search.util.QueryModel.Internal.AttrValue

  public void setId(Long id) {
    this.id = id;
  }

  public void addTarget(String namespace_identifier, Object value) {
    target_attrs.add(new AttrValue(namespace_identifier, value.toString()));
  }
View Full Code Here

Examples of org.jzkit.search.util.QueryModel.Internal.AttrValue

    if ( attr_set == null ) {
      attr_set = new AttributeSetDBO();
      valid_attributes.put(type,attr_set);
    }

    attr_set.getAttrs().add(new AttrValue(namespace,index_name));
  }
View Full Code Here

Examples of org.jzkit.search.util.QueryModel.Internal.AttrValue

    attr_set.getAttrs().add(new AttrValue(namespace,index_name));
  }

  public void registerTranslation(String from, String target_namespace, String target_index_name) {
    log.debug("registerTranslation "+from+" -> "+target_namespace+":"+target_index_name);
    service_specific_translations.put(from, new AttrValue(target_namespace,target_index_name));
  }
View Full Code Here

Examples of shared.AttrValue

   * @param instance
   * @param performance
   */
  protected void labelInstance(Instance instance, AttrInfo labelInfo,
      double performance) {
    AttrValue perfLabel = new AttrValue();
    labelInfo.set_nominal_string(perfLabel, perfClasses.get(PredictorGenerators
        .classifyPerformance(perfBorders, performance)), true);
    instance.set_label(perfLabel);
  }
View Full Code Here

Examples of shared.AttrValue

        throw new IllegalArgumentException("Attribute '" + confEntry.getKey()
            + "' could not be found in attrbute map!");
      }

      AttrInfo attrInfo = attrInfos.getFirstValue();
      AttrValue val = new AttrValue();

      if (attrInfo instanceof NominalAttrInfo) {
        attrInfo.set_nominal_string(val, confEntry.getValue().toString(), true);
      } else if (attrInfo instanceof RealAttrInfo) {
        attrInfo.set_real_val(val,
View Full Code Here

Examples of shared.AttrValue

   */
  static void setMissingAttribute(Instance instance,
      Pair<AttrInfo, Integer> attrInfos) {
    AttrInfo info = attrInfos.getFirstValue();
    int attribIndex = attrInfos.getSecondValue();
    AttrValue val = new AttrValue();

    if (info instanceof NominalAttrInfo) {
      info.set_nominal_string(val, MISSING_NOM_VAL, true);
    } else if (info instanceof RealAttrInfo) {
      info.set_real_val(val, MISSING_NUM_VAL);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.