public boolean shouldGenerateModel(ProtoModule module, Proto proto, Message m)
    {
        boolean generateModel = false;

        if (module.getOptions().containsKey("models"))
        {
            String optGenerateModel = module.getOption("models");
            generateModel =
                    optGenerateModel.equalsIgnoreCase("true") ||
                            optGenerateModel.equals("1");
        }
        else if (module.getOptions().containsKey("no_models"))
        {
            String optGenerateModel = module.getOption("no_models");
            generateModel =
                    !optGenerateModel.equalsIgnoreCase("true") &&
                            !optGenerateModel.equals("1");
        }

        if (proto.getOptions().containsKey("models"))
        {
            String optGenerateModel = proto.getExtraOption("models").toString();
            generateModel =
                    optGenerateModel.equalsIgnoreCase("true") ||
                            optGenerateModel.equals("1");
        }
        else if (proto.getOptions().containsKey("no_models"))
        {
            String optGenerateModel = proto.getExtraOption("no_models");
            generateModel =
                    !optGenerateModel.equalsIgnoreCase("true") &&
                            !optGenerateModel.equals("1");
        }

        if (m.getOptions().containsKey("model"))
        {
            String optGenerateModel = m.getExtraOption("model").toString();
            generateModel =
                    optGenerateModel.equalsIgnoreCase("true") ||
                            optGenerateModel.equals("1");
        }
        else if (m.getOptions().containsKey("no_model"))
        {
            String optGenerateModel = m.getExtraOption("no_model");
            generateModel =
                    !optGenerateModel.equalsIgnoreCase("true") &&
                            !optGenerateModel.equals("1");
        }

        return generateModel;
    }
Compiles proto files to protobuf java messages (pojos). Generates a {@code Schema} from the proto files.
<ul>
<li>Schemas are always separated from messages</li>
<li>Schemas are able to be inherited</li>
<li>Schemas have a lot of Annotation/Options to configure compiler output</li>
<li>@Transient support for Messages/Enumerations</li>
</ul>

@author Ivan Prisyazhniy
@created Mar 9, 2012
protostuff-compiler/src/main/java/io/protostuff/compiler/ProtoToJavaBeanModelCompiler.java