public void appendSecurityRole()

in src/main/java/org/apache/maven/plugins/ear/SecurityRole.java [93:127]


    public void appendSecurityRole( XMLWriter writer )
    {
        writer.startElement( SECURITY_ROLE );

        // role id
        if ( getRoleId() != null )
        {
            writer.addAttribute( ID_ATTRIBUTE, getRoleId() );
        }

        // description
        if ( getDescription() != null )
        {
            writer.startElement( DESCRIPTION );
            if ( getDescriptionId() != null )
            {
                writer.addAttribute( ID_ATTRIBUTE, getDescriptionId() );
            }
            writer.writeText( getDescription() );
            writer.endElement();

        }

        // role name
        writer.startElement( ROLE_NAME );
        if ( getRoleNameId() != null )
        {
            writer.addAttribute( ID_ATTRIBUTE, getRoleNameId() );
        }
        writer.writeText( getRoleName() );
        writer.endElement();

        // end of security-role
        writer.endElement();
    }