Package org.eclipse.jst.jsf.common.metadata

Examples of org.eclipse.jst.jsf.common.metadata.Entity


   * <!-- end-user-doc -->
   * @generated NOT
   */
  private Entity findTag(Model model, String tagid) {
    for (Iterator it=model.getChildEntities().iterator();it.hasNext();){
      Entity tag_ = (Entity)it.next();
      if (tagid.equals(tag_.getId()))
          return tag_;
    }
    return null;
  }
View Full Code Here


//    return registry.getElementDescriptor(uri, _element.getLocalName());
//  }

  private IPropertyDescriptor getAttrPropertyDescriptor(String attrName){
   
    Entity attrEntity = TaglibDomainMetaDataQueryHelper.getEntity(_tagEntity, attrName);
    List ppds = MetaDataEnabledProcessingFactory.getInstance().getAttributeValueRuntimeTypeFeatureProcessors(IPropertyPageDescriptor.class, _context, attrEntity);
    if (ppds.size() > 0)
      return (IPropertyDescriptor)((IPropertyPageDescriptor)ppds.get(0)).getAdapter(IPropertyDescriptor.class);
   
    return null;
View Full Code Here

     *         metadata context or null if not found.
     */
    public TagMapping getTagToViewMapping(final TagIdentifier tagId)
    {

    final Entity entity = _query.getQueryHelper().getEntity(tagId.getUri(), tagId.getTagName());
//        final ITaglibDomainMetaDataModelContext modelContext = createMetadataContext(tagId
//                .getUri());
//        final Entity entity = TaglibDomainMetaDataQueryHelper.getEntity(
//                modelContext, tagId.getTagName());
        if (entity != null)
View Full Code Here

     */
    public AttributeToPropertyMapping getAttributeMapping(
            final TagIdentifier tagId, final String name)
    {

        final Entity entity = _query.getQueryHelper().getEntity(
                tagId.getUri(), tagId.getTagName()+"/"+name); //$NON-NLS-1$
        if (entity != null)
        {
            final Trait trait = _query.getQueryHelper().getTrait(
                    entity, ViewMetadataMapper.DEFAULT_ATTRIBUTE_TRAIT_ID);
View Full Code Here

                                              final String attributeName)
        {
            final String entityKey = elementName+"/"+attributeName; //$NON-NLS-1$
        final IMetaDataDomainContext context = MetaDataQueryContextFactory.getInstance().createTaglibDomainModelContext(file);
        final ITaglibDomainMetaDataQuery query = MetaDataQueryFactory.getInstance().createQuery(context);
        final Entity entity = query.getQueryHelper().getEntity(uri, entityKey);
        Trait trait = query.getQueryHelper().getTrait(entity, CONTRIBUTES_VALUE_BINDING);
//            final ITaglibDomainMetaDataModelContext mdContext = TaglibDomainMetaDataQueryHelper.createMetaDataModelContext(project, uri);
//            Trait trait = TaglibDomainMetaDataQueryHelper.getTrait(mdContext, entityKey, CONTRIBUTES_VALUE_BINDING);

            final boolean contribsValueBindings = TraitValueHelper.getValueAsBoolean(trait);
View Full Code Here

    return pds;
  }

  private IPropertyPageDescriptor getPD(Entity tagEntity, String attrName) {   
    IPropertyPageDescriptor pd = null;
    Entity attrEntity = getAttributeEntity(tagEntity, attrName);
    if (attrEntity != null){
      List pds = MetaDataEnabledProcessingFactory.getInstance().getAttributeValueRuntimeTypeFeatureProcessors(
              IPropertyPageDescriptor.class, getStructuredDocumentContext(), attrEntity);         
      if (pds != null && !pds.isEmpty())
        pd = (IPropertyPageDescriptor)pds.get(0);
View Full Code Here

                {
                    return pi.getTagCreation();
                }
            }
            // tag-creation trait on entity directly?
            final Entity tag = query.findTagEntity(model, tagName);
            if (tag != null)
            {// metadata exists
                trait = query.findTrait(tag,
                        "tag-create"); //$NON-NLS-1$
                if (trait != null && trait.getValue() != null)
View Full Code Here

        }
      } 
    }
    if (icon == null) {
      for (Iterator it=model.getChildEntities().iterator();it.hasNext();){
        Entity tagAsEntity = (Entity)it.next();
        if (tagAsEntity.getId().equalsIgnoreCase(tagName)){                   
          if (small)
            icon = getImageDescriptorFromTagTraitValueAsString(query, tagAsEntity, TRAIT_ICON_SMALL, DEFAULT_SMALL_ICON);
          else
            icon = getImageDescriptorFromTagTraitValueAsString(query, tagAsEntity, TRAIT_ICON_LARGE, DEFAULT_LARGE_ICON)
         
View Full Code Here

          createTagEntry(category, tag, doc);
        }
      } else {
        for (final Iterator it = model.getChildEntities().iterator(); it
            .hasNext();) {
          final Entity tagAsEntity = (Entity) it.next();
          createTagEntry(category, tagAsEntity, doc);
        }
      }
    } else {// fail safe loading from cmDoc... should no longer go in here
      loadFromCMDocument(category, doc);
View Full Code Here

          createTagEntry(category, tag, ns);
        }
      } else {
        for (final Iterator it = model.getChildEntities().iterator(); it
            .hasNext();) {
          final Entity tagAsEntity = (Entity) it.next();
          createTagEntry(category, tagAsEntity, ns);
        }
      }
    } else {// fail safe loading from cmDoc... should no longer go in here
      loadFromNamespace(category, ns);
View Full Code Here

TOP

Related Classes of org.eclipse.jst.jsf.common.metadata.Entity

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.