public Map<Object, Object> getUserData() { return delegate.getUserData(); }
private void setMappedIndex(Attribute att, int index) { att.getUserData().put(ComplexFeatureConstants.MAPPED_ATTRIBUTE_INDEX, index); }
@SuppressWarnings("unchecked") public void setValue(Object value) { if (!name.getLocalPart().equals("id")) { Map<Name, Object> map = (Map<Name, Object>) feature.getUserData().get(Attributes.class); if (map != null) { map.put(name, value); } } }
Attribute leafAttribute, Map<Object, Object> simpleContentProperties) { Map<Object, Object> origData = leafAttribute.getUserData(); for (Object key : simpleContentProperties.keySet()) { if (key.equals(Attributes.class)) {
if (target.getUserData().containsValue(Attributes.class)) { targetAttributes.putAll( (Map<? extends Name, ? extends Object>) target.getUserData().get(Attributes.class)); target.getUserData().put(Attributes.class, targetAttributes);
if (target.getUserData().containsValue(Attributes.class)) { targetAttributes.putAll( (Map<? extends Name, ? extends Object>) target.getUserData().get(Attributes.class)); target.getUserData().put(Attributes.class, targetAttributes);
private void setPathIndex(Attribute att, StepList sl) { Object index = att.getUserData().get(ComplexFeatureConstants.MAPPED_ATTRIBUTE_INDEX); if (index != null) { int mappedIndex = Integer.parseInt(String.valueOf(index)); // get prefixed attribute name Name attName = att.getName(); String nsPrefix = namespaces.getPrefix(attName.getNamespaceURI()); String xpath = nsPrefix + ":" + attName.getLocalPart(); // set the index of the attribute in the attribute mapping steps sl.setIndex(mappedIndex, xpath, XPATH_SEPARATOR); } }
@SuppressWarnings("unchecked") public Object getImmediateNode() { // first try regular way if (feature instanceof ComplexAttribute) { ComplexAttribute ca = (ComplexAttribute) feature; Property p = ca.getProperty("@" + name.getLocalPart()); if (p != null) { return p; } } // FIXME - better id checking if (name.getLocalPart().equals("id")) { Identifier id = feature.getIdentifier(); if (id != null) { return id.getID(); } } Map<Name, Object> map = (Map<Name, Object>) feature.getUserData().get(Attributes.class); if (map != null) { return map.get(name); } else { return null; } }
Object mappedIndex = stepValue .getUserData() .get( ComplexFeatureConstants if (index > -1) { if (stepValue .getUserData() .containsKey( ComplexFeatureConstants String.valueOf( stepValue .getUserData() .get( ComplexFeatureConstants && leafAttribute.getUserData().containsKey(Attributes.class) && ((Map<Object, Object>) leafAttribute.getUserData().get(Attributes.class)) .containsKey(AbstractMappingFeatureIterator.XLINK_HREF_NAME))) { AppSchemaAttributeBuilder builder = new AppSchemaAttributeBuilder(featureFactory); .getUserData() .put(ComplexFeatureConstants.MAPPED_ATTRIBUTE_INDEX, index);
public Map<Object, Object> getUserData() { return delegate.getUserData(); }
private void setMappedIndex(Attribute att, int index) { att.getUserData().put(ComplexFeatureConstants.MAPPED_ATTRIBUTE_INDEX, index); }
@SuppressWarnings("unchecked") public void setValue(Object value) { if (!name.getLocalPart().equals("id")) { Map<Name, Object> map = (Map<Name, Object>) feature.getUserData().get(Attributes.class); if (map != null) { map.put(name, value); } } }
@SuppressWarnings("unchecked") public void setValue(Object value) { if (!name.getLocalPart().equals("id")) { Map<Name, Object> map = (Map<Name, Object>) feature.getUserData().get(Attributes.class); if (map != null) { map.put(name, value); } } }
assertNotNull("sa:sampledFeature evaluated to null", sampledFeatureVal); assertEquals(0, ((Collection) sampledFeatureVal.getValue()).size()); Map attributes = (Map) sampledFeatureVal.getUserData().get(Attributes.class); assertNotNull(attributes); Name xlinkTitle = name(XLINK.NAMESPACE, "title");
Map<Object, Object> simpleContentProperties) { Map<Object, Object> origData = leafAttribute.getUserData(); for (Object key : simpleContentProperties.keySet()) { if (key.equals(Attributes.class)) {
if (target.getUserData().containsValue(Attributes.class)) { targetAttributes.putAll((Map<? extends Name, ? extends Object>) target.getUserData() .get(Attributes.class)); target.getUserData().put(Attributes.class, targetAttributes);
@SuppressWarnings("unchecked") public Object getImmediateNode() { //FIXME - better id checking if (name.getLocalPart().equals("id")) { return feature.getIdentifier().getID(); } else { Map<Name, Object> map = (Map<Name, Object>) feature.getUserData().get(Attributes.class); if (map != null) { return map.get(name); } else { return null; } } }
if (target.getUserData().containsValue(Attributes.class)) { targetAttributes.putAll((Map<? extends Name, ? extends Object>) target.getUserData() .get(Attributes.class)); target.getUserData().put(Attributes.class, targetAttributes);
private void setPathIndex(Attribute att, StepList sl) { Object index = att.getUserData().get(ComplexFeatureConstants.MAPPED_ATTRIBUTE_INDEX); if (index != null) { int mappedIndex = Integer.parseInt(String.valueOf(index)); // get prefixed attribute name Name attName = att.getName(); String nsPrefix = namespaces.getPrefix(attName.getNamespaceURI()); String xpath = nsPrefix + ":" + attName.getLocalPart(); // set the index of the attribute in the attribute mapping steps sl.setIndex(mappedIndex, xpath, XPATH_SEPARATOR); } }
@SuppressWarnings("unchecked") public Object getImmediateNode() { // first try regular way if (feature instanceof ComplexAttribute) { ComplexAttribute ca = (ComplexAttribute) feature; Property p = ca.getProperty("@" + name.getLocalPart()); if (p != null) { return p; } } // FIXME - better id checking if (name.getLocalPart().equals("id")) { Identifier id = feature.getIdentifier(); if (id != null) { return id.getID(); } } Map<Name, Object> map = (Map<Name, Object>) feature.getUserData().get(Attributes.class); if (map != null) { return map.get(name); } else { return null; } }