private boolean appendKeywordSourceViolations()

in modello-plugins/modello-plugin-jpox/src/main/java/org/apache/archiva/redback/components/modello/jpox/JPoxJdoMappingModelloGenerator.java [636:673]


    private boolean appendKeywordSourceViolations( String word, StringBuffer emsg )
    {
        List sources = sqlReservedWords.getKeywordSourceList( word );
        boolean hasError = false;
        emsg.append( "  Violation Source(s): " );
        for ( Iterator it = sources.iterator(); it.hasNext(); )
        {
            KeywordSource source = (KeywordSource) it.next();
            emsg.append( source.getName() ).append( " (" ).append( source.getSeverity() ).append( ")" );
            emsg.append( EOL );

            if ( source.getSeverity().equalsIgnoreCase( "ERROR" ) )
            {
                hasError = true;
            }

            if ( it.hasNext() )
            {
                emsg.append( "                       " );
            }
        }
        emsg.append( " " ).append( EOL );

        emsg.append( "  Severity: " );
        if ( hasError )
        {
            emsg.append( "ERROR - You must change this name for the maximum" ).append( EOL );
            emsg.append( "            compatibility amoungst JDBC SQL Servers." ).append( EOL );
        }
        else
        {
            emsg.append( "WARNING - You are encouraged to change this name" ).append( EOL );
            emsg.append( "            for maximum compatibility amoungst JDBC SQL Servers." ).append( EOL );
        }
        emsg.append( " " ).append( EOL );

        return hasError;
    }