Examples of SimpleAttribute


Examples of cambridge.model.SimpleAttribute

        this.expression = expression;
    }

    public void modify(Map<String, Object> bindings, ModifyableTag tag) throws ExpressionEvaluationException {
        if (expression.asBoolean(bindings)) {
            tag.getTagParts().add(new SimpleAttribute("selected", "selected", getLine(), getCol()));
        }
    }
View Full Code Here

Examples of cambridge.model.SimpleAttribute

                                 break;
                           }
                        }

                        if (fragments.size() == 0 || fragments.size() == 1 && fragments.get(0) instanceof StaticFragment) {
                           element = new SimpleAttribute(currentToken.getLineNo(), currentToken.getColumn());
                           ((SimpleAttribute) element).setValue(currentToken.value);
                        } else {
                           element = new ComplexAttribute(currentToken.getLineNo(), currentToken.getColumn());
                           ((ComplexAttribute) element).setFragments(fragments);
                           AttributeValueToken aTok = (AttributeValueToken) currentToken;
View Full Code Here

Examples of cambridge.model.SimpleAttribute

    public void modify(TemplateDocument doc, String value, TagNode t) {
        ArrayList<Tag> tags = t.getElementsByTagName("img");
        for (Tag tag : tags) {
            if (!tag.hasAttribute("alt")) {
                tag.addAttribute(new SimpleAttribute("alt", "", line, col));
            }
        }
        if (t.getTagName().equalsIgnoreCase("img")) {
            if (!t.hasAttribute("alt")) {
                t.addAttribute(new SimpleAttribute("alt", "", line, col));
            }
        }
    }
View Full Code Here

Examples of org.hibernate.metamodel.source.annotations.attribute.SimpleAttribute

    );

    AttributeType attributeType = determineAttributeType( annotations );
    switch ( attributeType ) {
      case BASIC: {
        SimpleAttribute attribute = SimpleAttribute.createSimpleAttribute(
            attributeName,
            type.getName(),
            annotations
        );
        if ( attribute.isId() ) {
          idAttributeMap.put( attributeName, attribute );
        }
        else {
          simpleAttributeMap.put( attributeName, attribute );
        }
View Full Code Here

Examples of org.hibernate.metamodel.source.annotations.attribute.SimpleAttribute

  private void bindDiscriminatorColumn(EntityBinding entityBinding) {
    final Map<DotName, List<AnnotationInstance>> typeAnnotations = JandexHelper.getTypeAnnotations(
        entityClass.getClassInfo()
    );
    SimpleAttribute discriminatorAttribute = SimpleAttribute.createDiscriminatorAttribute( typeAnnotations );
    bindSingleMappedAttribute( entityBinding, entityBinding.getEntity(), discriminatorAttribute );
  }
View Full Code Here

Examples of org.hibernate.metamodel.source.annotations.attribute.SimpleAttribute

  @Override
  public IdentifierSource getIdentifierSource() {
    IdType idType = getEntityClass().getIdType();
    switch ( idType ) {
      case SIMPLE: {
        SimpleAttribute attribute = getEntityClass().getIdAttributes().iterator().next();
        return new SimpleIdentifierSourceImpl( attribute );
      }
      case COMPOSED: {
        break;
      }
View Full Code Here

Examples of org.hibernate.metamodel.source.annotations.attribute.SimpleAttribute

    );

    AttributeType attributeType = determineAttributeType( annotations );
    switch ( attributeType ) {
      case BASIC: {
        SimpleAttribute attribute = SimpleAttribute.createSimpleAttribute( attributeName, type, annotations );
        if ( attribute.isId() ) {
          idAttributeMap.put( attributeName, attribute );
        } else if (attribute.isVersioned()) {
          // todo - error handling in case there are multiple version attributes
          versionAttribute = attribute;
        }
        else {
          simpleAttributeMap.put( attributeName, attribute );
View Full Code Here

Examples of org.jboss.identity.idm.impl.api.SimpleAttribute

     
      org.jboss.identity.idm.api.User idUser= identitySession.getPersistenceManager().createUser(userName);
     
      List<Attribute> attrs = new ArrayList<Attribute>();
      if (givenName != null) {
        attrs.add(new SimpleAttribute(P3PConstants.INFO_USER_NAME_GIVEN, givenName));
      }
      if (familyName != null) {
        attrs.add(new SimpleAttribute(P3PConstants.INFO_USER_NAME_FAMILY, familyName));
      }
      if (businessEmail != null) {
        attrs.add(new SimpleAttribute(P3PConstants.INFO_USER_BUSINESS_INFO_ONLINE_EMAIL, businessEmail));
      }
           
      identitySession.getAttributesManager().addAttributes(idUser, attrs.toArray(new Attribute[attrs.size()]));
      return idUser.getId();
     
View Full Code Here

Examples of org.jboss.identity.idm.impl.api.SimpleAttribute

   {
      checkNotNullArgument(identity, "IdentityType");
      checkNotNullArgument(attributeName, "Attribute name");
      checkNotNullArgument(values, "Attribute values");

      Attribute[] attrs = new Attribute[]{new SimpleAttribute(attributeName, values)};

      addAttributes(identity, attrs);
   }
View Full Code Here

Examples of org.jboss.identity.idm.impl.api.SimpleAttribute

   {
      checkNotNullArgument(identity, "IdentityType");
      checkNotNullArgument(attributeName, "Attribute name");
      checkNotNullArgument(value, "Attribute value");

      Attribute[] attrs = new Attribute[]{new SimpleAttribute(attributeName, value)};


      addAttributes(identity, attrs);

   }
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.