Examples of IMetaTag


Examples of org.apache.flex.compiler.definitions.metadata.IMetaTag

     * This method is in DefinitionBase because it is common to
     * VariableDefinition, GetterDefinition, and SetterDefinition.
     */
    public boolean hasRichTextContent(FlexProject project)
    {
        IMetaTag metaTag = getPropertyMetaTag(
                project, IMetaAttributeConstants.ATTRIBUTE_RICHTEXTCONTENT);

        return metaTag != null;
    }

Examples of org.apache.flex.compiler.definitions.metadata.IMetaTag

     * This method is in DefinitionBase because it is common to
     * VariableDefinition, GetterDefinition, and SetterDefinition.
     */
    public boolean hasCollapseWhiteSpace(FlexProject project)
    {
        IMetaTag metaTag = getPropertyMetaTag(
                project, IMetaAttributeConstants.ATTRIBUTE_COLLAPSEWHITESPACE);

        return metaTag != null;
    }

Examples of org.apache.flex.compiler.definitions.metadata.IMetaTag

     * This method is in DefinitionBase because it is common to
     * VariableDefinition, GetterDefinition, and SetterDefinition.
     */
    public boolean isColor(FlexProject project)
    {
        IMetaTag metaTag = getPropertyMetaTag(
                project, IMetaAttributeConstants.ATTRIBUTE_INSPECTABLE);

        if (metaTag == null)
            return false;

        String format = metaTag.getAttributeValue(IMetaAttributeConstants.NAME_INSPECTABLE_FORMAT);
        return format.equals(IMetaAttributeConstants.VALUE_INSPECTABLE_FORMAT_COLOR);
    }

Examples of org.apache.flex.compiler.definitions.metadata.IMetaTag

    }

    private IMetaTag getPropertyMetaTag(FlexProject project, String metadataName)
    {
        // Look for metadata with the specified name.
        IMetaTag metaTag = getMetaTagByName(metadataName);

        // If we don't find it, and we're a getter or setter,
        // look on the corresponding setter or getter.
        if (metaTag == null && this instanceof IAccessorDefinition)
        {

Examples of org.apache.flex.compiler.definitions.metadata.IMetaTag

     * {@code getInstanceType()}.
     */
    private String getPropertyMetaTagValue(FlexProject project, String metadataName)
    {
        // Look for metadata with the specified name.
        IMetaTag metaTag = getPropertyMetaTag(project, metadataName);

        // If we found the metadata, return the type that it specifies.
        // There should be one keyless attribute, and we want its value.
        return metaTag != null ? metaTag.getValue() : null;
    }

Examples of org.apache.flex.compiler.definitions.metadata.IMetaTag

        Collection<VariableDefinition> variables = getAllLocalVariables();

        List<IMetaTag> parts = new LinkedList<IMetaTag>();
        for (VariableDefinition variable : variables)
        {
            IMetaTag skinPart = variable.getSkinPart();
            if (skinPart != null)
                parts.add(skinPart);
        }

        Collection<GetterDefinition> getters = getAllLocalGetters();
        for (GetterDefinition getter : getters)
        {
            IMetaTag skinPart = getter.getSkinPart();
            if (skinPart != null)
                parts.add(skinPart);
        }

        for (IMetaTag part : parts)

Examples of org.apache.flex.compiler.definitions.metadata.IMetaTag

        if (remoteClassTags.length != 0)
        {
            // Reading the source for the Flex 4.5.X compiler, it seems that
            // you can only have one alias for each class and that the last alias
            // wins.
            IMetaTag lastRemoteClassTag = remoteClassTags[remoteClassTags.length - 1];
            remoteClassAlias = lastRemoteClassTag.getAttributeValue(IMetaAttributeConstants.NAME_REMOTECLASS_ALIAS);
            // Goofy logic copied from flex2.compiler.as3.SyntaxTreeEvaluator.
            // Original code references a bug number 159983 in an unknown bug base.
            if (remoteClassAlias == null)
                remoteClassAlias = "<" + getQualifiedName();
        }

Examples of org.apache.flex.compiler.definitions.metadata.IMetaTag

    public String getDefaultPropertyName(ICompilerProject project)
    {
        // Look for [DefaultProperty("foo")] on this class its superclasses.
        for (IClassDefinition c : classIterable(project, true))
        {
            IMetaTag defaultPropertyMetaData = c.getMetaTagByName(IMetaAttributeConstants.ATTRIBUTE_DEFAULTPROPERTY);
            if (defaultPropertyMetaData != null)
            {
                IMetaTagAttribute attrs[] = defaultPropertyMetaData.getAllAttributes();
                if ((attrs.length == 1) && (!attrs[0].hasKey()))
                    return attrs[0].getValue();
            }
        }
        return null;

Examples of org.apache.flex.compiler.definitions.metadata.IMetaTag

     * {@inheritDoc}
     */
    @Override
    public int getNameStart()
    {
        final IMetaTag goToDefinitionHelp =
                getMetaTagByName(IMetaTag.GO_TO_DEFINITION_HELP);
        if (goToDefinitionHelp != null)
        {
            final String value = goToDefinitionHelp.getAttributeValue(
                    IMetaTag.GO_TO_DEFINITION_HELP_POS);
            if (Strings.isNullOrEmpty(value))
            {
                return UNKNOWN;
            }

Examples of org.apache.flex.compiler.definitions.metadata.IMetaTag

    {
        IFileScopeRequestResult result = compilationUnit.getFileScopeRequest().get();

        for(IDefinition def : result.getExternallyVisibleDefinitions())
        {
            IMetaTag md = def.getMetaTagByName(IMetaAttributeConstants.ATTRIBUTE_MIXIN);
            if (md != null)
                mixinClassNames.add(def.getQualifiedName());
        }
    }
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.