{"id":33147001,"url":"https://github.com/mkarneim/pojobuilder","last_synced_at":"2025-11-20T07:02:40.888Z","repository":{"id":538142,"uuid":"2469892","full_name":"mkarneim/pojobuilder","owner":"mkarneim","description":"A Java Code Generator for Pojo Builders","archived":false,"fork":false,"pushed_at":"2025-08-18T16:35:49.000Z","size":7405,"stargazers_count":334,"open_issues_count":24,"forks_count":43,"subscribers_count":20,"default_branch":"master","last_synced_at":"2025-08-18T18:28:47.179Z","etag":null,"topics":["annotation-processor","builder","java","pojobuilder"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mkarneim.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"COPYING","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2011-09-27T18:58:30.000Z","updated_at":"2025-02-05T14:27:26.000Z","dependencies_parsed_at":"2025-08-18T18:15:44.009Z","dependency_job_id":"baab2744-5849-4c75-a0c3-141d0d9ec291","html_url":"https://github.com/mkarneim/pojobuilder","commit_stats":null,"previous_names":[],"tags_count":29,"template":false,"template_full_name":null,"purl":"pkg:github/mkarneim/pojobuilder","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mkarneim%2Fpojobuilder","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mkarneim%2Fpojobuilder/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mkarneim%2Fpojobuilder/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mkarneim%2Fpojobuilder/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mkarneim","download_url":"https://codeload.github.com/mkarneim/pojobuilder/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mkarneim%2Fpojobuilder/sbom","scorecard":{"id":393945,"data":{"date":"2025-08-11","repo":{"name":"github.com/mkarneim/pojobuilder","commit":"9fed8982bc1015b5b14570a5823397a4076664d1"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.8,"checks":[{"name":"Code-Review","score":2,"reason":"Found 6/26 approved changesets -- score normalized to 2","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Binary-Artifacts","score":9,"reason":"binaries present in source code","details":["Warn: binary detected: gradle/wrapper/gradle-wrapper.jar:1"],"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":9,"reason":"license file detected","details":["Info: project has a license file: COPYING:0","Warn: project license file does not contain an FSF or OSI license."],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Signed-Releases","score":0,"reason":"Project has not signed or included provenance with any releases.","details":["Warn: release artifact v4.2.3 not signed: https://api.github.com/repos/mkarneim/pojobuilder/releases/16017295","Warn: release artifact v4.2.2 not signed: https://api.github.com/repos/mkarneim/pojobuilder/releases/10686758","Warn: release artifact v4.2.1 not signed: https://api.github.com/repos/mkarneim/pojobuilder/releases/10493201","Warn: release artifact v4.2.3 does not have provenance: https://api.github.com/repos/mkarneim/pojobuilder/releases/16017295","Warn: release artifact v4.2.2 does not have provenance: https://api.github.com/repos/mkarneim/pojobuilder/releases/10686758","Warn: release artifact v4.2.1 does not have provenance: https://api.github.com/repos/mkarneim/pojobuilder/releases/10493201"],"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 10 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-18T18:29:27.017Z","repository_id":538142,"created_at":"2025-08-18T18:29:27.017Z","updated_at":"2025-08-18T18:29:27.017Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":285389437,"owners_count":27163377,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-11-20T02:00:05.334Z","response_time":54,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["annotation-processor","builder","java","pojobuilder"],"created_at":"2025-11-15T13:00:40.320Z","updated_at":"2025-11-20T07:02:40.880Z","avatar_url":"https://github.com/mkarneim.png","language":"Java","funding_links":[],"categories":["Libs"],"sub_categories":["\u003cA NAME=\"Code_Generation\"\u003e\u003c/A\u003eCode Generation"],"readme":"PojoBuilder -  A Code Generator for Pojo Builders\n=================================================\n[![Build Status](https://travis-ci.org/mkarneim/pojobuilder.svg?branch=master)](https://travis-ci.org/mkarneim/pojobuilder)\n[![Coverage Status](https://coveralls.io/repos/mkarneim/pojobuilder/badge.png?branch=master)](https://coveralls.io/r/mkarneim/pojobuilder?branch=master)\n\nAuthor: Michael Karneim\n\nProject Homepage: http://github.com/mkarneim/pojobuilder\n\nAbout\n-----\n\nPojoBuilder is a Java annotation processor that creates a fluent builder class for POJOs (Plain Old Java Object).\n\nThe generated builder offers:\n\n* A fluent interface to set the pojo's properties.\n* A build() method that creates a new pojo instance with the given values.\n\nYou can use a generated pojo builder like this:\n\n```java\n\tContact james = new ContactBuilder()\n\t\t.withSurname(\"Bond\")\n\t\t.withFirstname(\"James\")\n\t\t.withEmail(\"007@secretservice.org\")\n\t\t.build();\n```\nBuilders can help you create test data by letting you set only the relevant properties.\n\nFor more details on:\n\n* Test data builders, see http://c2.com/cgi/wiki?TestDataBuilder and http://www.natpryce.com/articles/000714.html (by Nat Pryce).\n* The builder pattern, see http://en.wikipedia.org/wiki/Builder_pattern.\n* Fluent interfaces, see http://www.martinfowler.com/bliki/FluentInterface.html (by Martin Fowler)\n\nLicense and Dependencies\n------------------------\nThe source code in the \"src\" directory is in the PUBLIC DOMAIN.\nFor details, read the [COPYING] file.\n\nPojoBuilder is a code generator. It does not add runtime dependencies to your project.\n\nIt adds one compile-time dependency with its own license:\n\n* [JavaWriter] 2.5.0 (see [license](http://github.com/mkarneim/pojobuilder/blob/master/license/javawriter-apache-license.txt))\n\n\nDownload\n--------\nPojoBuilder is open source. The source code is available at\nhttp://github.com/mkarneim/pojobuilder.\nFor older versions and a change log, see the [release history page].\n\nPojoBuilder binaries are available at [Sonatype OSS Maven Repository] and [Maven Central].\n\nIf you do not use a build automation tool that supports Maven repos, download the [`pojobuilder-4.3.1-jar-with-dependencies.jar`] to get PojoBuilder with all its dependencies.\n\nHow To Use\n----------\n\nPojoBuilder uses an annotation processor to generate pojo builders.\nYou can trigger code generation during compilation by:\n\n* [annotating a pojo's constructor](#annotating-a-constructor)\n* [annotating the pojo class](#annotating-the-pojo)\n* [annotating a factory method](#annotating-a-factory-method)\n\n### Annotating a Constructor ###\n\nTo generate a builder, annotate one of the pojo's constructors with `@GeneratePojoBuilder`.\n\nExample:\n```java\npublic class Contact {\n  private final String surname;\n  private final String firstname;\n  private String email;\n\n  @GeneratePojoBuilder\n  public Contact(String surname, String firstname) {\n    this.surname = surname;\n    this.firstname = firstname;\n  }\n\n  public String getEmail() {\n    return email;\n  }\n\n  public void setEmail(String email) {\n    this.email = email;\n  }\n\n  public String getSurname() {\n    return surname;\n  }\n\n  public String getFirstname() {\n    return firstname;\n  }\n}\n```\nThe [@GeneratePojoBuilder] annotation tells the processor to create a source file named `ContactBuilder`. Check [`ContactBuilder.java`] to see the generated code.\n\nEnsure the constructor is public or accessible to the generated builder (for example, if it is protected, the builder must be in the same package).\n\nAlso, the constructor parameter names must match the pojo's property names exactly.\n\nYou can use an optional [@ConstructorProperties] annotation to map constructor parameter names to bean property names if they differ.\n```java\npublic class Contact {\n  private final String surname;\n  private final String firstname;\n  private String email;\n\n  @GeneratePojoBuilder\n  @ConstructorProperties({\"surname\",\"firstname\"})\n  public Contact(String arg1, String arg2) {\n    this.surname = arg1;\n    this.firstname = arg2;\n  }\n\n  public String getEmail() {\n    return email;\n  }\n\n  public void setEmail(String email) {\n    this.email = email;\n  }\n\n  public String getSurname() {\n    return surname;\n  }\n\n  public String getFirstname() {\n    return firstname;\n  }\n}\n```\n\n### Annotating the Pojo ###\n\nIf your pojo does not define a specific constructor, has only a public default constructor, or defines exactly one constructor, annotate the class with @GeneratePojoBuilder..\n\nExample:\n```java\n@GeneratePojoBuilder\npublic class User {\n  private String name;\n  private char[] password;\n\n  public String getName() {\n    return name;\n  }\n\n  public void setName(String name) {\n    this.name = name;\n  }\n\n  public char[] getPassword() {\n    return password;\n  }\n\n  public void setPassword(char[] password) {\n    this.password = password;\n  }\n}\n```\n\nSee [`UserBuilder.java`] to review the generated code.\n\n### Annotating a Factory Method ###\n\nIf you cannot modify the pojo's source or prefer not to annotate the pojo, annotate a factory method:\n\n```java\npublic class UrlFactory {\n\n  @GeneratePojoBuilder(withName=\"UrlBuilder\", intoPackage = \"samples\")\n  public static URL createUrl(\n    String protocol, String host, int port, String file, URLStreamHandler handler)\n      throws MalformedURLException {\n    return new URL(protocol, host, port, file, handler);\n  }\n}\n```\nCheck [`UrlBuilder.java`] to see the generated code.\n\nEnsure the factory method is public and static. Its parameter names must match the pojo's property names exactly.\n\nYou can use an optional [@FactoryProperties] annotation to map the parameter names if needed.\n```java\npublic class FileFactory {\n\n  @GeneratePojoBuilder(intoPackage = \"samples\")\n  @FactoryProperties({\"path\"})\n  public static File createFile(String arg1) {\n    return new File(arg1);\n  }\n}\n```\nSee [`FileBuilder.java`] for the generated code.\n\n### Annotating a Record ###\n\nStarting with PojoBuilder 4.3, you can annotate a Java 17 record:\n\n```java\n@GeneratePojoBuilder\npublic record MyRecord(int x, int y, String blah) {}\n```\n\n### Directives ###\nYou can use the following elements of [@GeneratePojoBuilder] to configure code generation:\n\n* **withName=\u0026lt;String\u0026gt;**\n  specifies the pattern of the builder's name. An asterisk will be\n  replaced with the pojos simple name. For example, the result of the pattern `Fluent*Builder` will become\n  `FluentContactBuilder` if the pojo's name is `Contact`. The default pattern is `*Builder`.\n* **withConstructor=\u0026lt;Visibility\u0026gt;**\n  Specifies the visibility of the builder's constructor.\n  Default is `Visibility.PUBLIC`.\n* **intoPackage=\u0026lt;String\u0026gt;**\n  specifies the package of the generated builder. An asterisk will be\n  replaced with the pojos package. For example, the result of the pattern `*.util` will become\n  `com.example.util` if the pojo's package is `com.example`. The default pattern is `*`.\n* **withBaseclass=\u0026lt;Class\u0026gt;**\n  specifies the base class of the generated builder. The default class is `Object.class`.\n* **withBuilderInterface=\u0026lt;Class\u0026gt;**\n  specifies the interface of the generated builder. The interface must declare exactly one type parameter\n  and a build method with this type as return type.\n  For an example please see [`Address.java`], [`Builder.java`] and [`AddressBuilder.java`].\n  Default is `Void.class`, which means, that no interface should be implemented.\n* **withBuilderProperties=\u0026lt;boolean\u0026gt;**\n  specifies whether the generated builder should define builder-based with-methods using the\n  builder interface (see above).\n  For an example please see [`Recipient.java`], [`Builder.java`] and [`RecipientBuilder.java`].\n  Default is `false`.\n* **includeProperties=\u0026lt;String[]\u0026gt;**\n  specifies which of the pojo's properties will be included into the generated builder. All properties that match any\n  [property pattern] in the specified array will be included. All other non-mandatory properties will be excluded.\n  Mandatory properties are those which are passed as constructor or factory method arguments. They will never be\n  excluded, neither explicitly nor implicitly.\n  For an example please see [`InputSourceFactory.java`] and [`InputSourceBuilder.java`].\n  Default is `*`.\n* **excludeProperties=\u0026lt;String[]\u0026gt;**\n  specifies which of the pojo's properties will be excluded from the generated builder. All property that match any\n  [property pattern] in the specified array will be excluded, except those that are mandatory. Mandatory properties are\n  those which are passed as constructor or factory method arguments. They will never be excluded, neither explicitly\n  nor implicitly.\n  For an example please see [`CalendarFactory.java`] and [`GregorianCalendarBuilder.java`].\n  Default is the empty array.\n* **withGenerationGap=\u0026lt;boolean\u0026gt;**\n  specifies whether the [generation gap pattern] is used. If enabled, this\n  will generate two classes (instead of one), of which one contains the\n  ordinary builder code, whereas the other class extends the first one and is an empty template for handwritten code.\n  Please move it out of the generated-sources folder to prevent it from being overwritten.\n  For examples please see [`Player.java`], [`PlayerBuilder.java`], and [`AbstractPlayerBuilder.java`].\n  Default is `false`.\n* **withCopyMethod=\u0026lt;boolean\u0026gt;**\n  specifies whether a copy method should be generated. Use the copy\n  method to initialize the builder's values from a given pojo instance.\n  For an example please see [`TextEmail.java`] and [`TextEmailBuilder.java`].\n  Default is `false`.\n* **withOptionalProperties=\u0026lt;Class\u0026gt;**\n  specifies whether the generated builder should define optional-based setter-methods using the\n  specified 'Optional' type. Examples are Google Guava's `com.google.common.base.Optional` and\n  `java.util.Optional` introduced with Java 8. Default is `Void.class`, which means,\n  that no optional-based setter-methods are generated.\n* **withSetterNamePattern=\u0026lt;String\u0026gt;**\n  specifies the name pattern of the generated setter-methods. An asterisk will be replaced with\n  the property's original name. Default is `with*`.\n* **withValidator=\u0026lt;Class\u0026gt;**\n  specifies the validator class that should be used to validate the created pojo. The class must\n  define a `validate` method having one parameter that is compatible with the pojo's\n  type. If the validation fails, the method must throw some runtime exception (or one of its\n  subclasses).\n  For an example please see [`Credentials.java`], [`CredentialsValidator.java`] and [`CredentialsBuilder.java`].\n* **withFactoryMethod=\u0026lt;String\u0026gt;**\n\tspecifies the name of a static factory method added to the builder class which creates a builder instance.\n\tAn asterisk will be replaced by the pojos simple name.\n\tFor an example please see [`Task.java`] and [`TaskBuilder.java`].\n\tDefault is `\"\"` meaning not to generate this method.\n\n### Default Configuration and Meta-Annotations ###\nStarting with version 3, PojoBuilder supports meta-annotations. You can place [@GeneratePojoBuilder] on another annotation, and it will be inherited.\n\nBenefits:\n* Share common PojoBuilder directives in one place.\n* Combine directives for other libraries that support meta-annotations.\n\nExample:\n```java\n@GeneratePojoBuilder(withName = \"Fluent*Builder\")\n@lombok.experimental.Value // class-level annotation from Lombok\n@javax.annotation.concurrent.Immutable // class-level annotation from JSR-305\n@Target({ElementType.TYPE, ElementType.ANNOTATION_TYPE})\npublic @interface AppPojo {\n}\n```\n\nApply it to your pojos:\n```java\n@AppPojo\npublic class Contact {\n  public String name;\n}\n```\nPojoBuilder generates `FluentContactBuilder` based on the directives from `@AppPojo`.\n\nYou can override meta-annotation defaults with a local `@GeneratePojoBuilder`:\n```java\n@AppPojo\n@GeneratePojoBuilder(intoPackage = \"builder\")\npublic class Contact {\n  public String name;\n}\n```\nThis generates `FluentContactBuilder` in the package `builder`.\n\nExamples\n--------\nThe [PojoBuilder wiki] offers a [cookbook] on using PojoBuilder to create a domain-specific language for tests.\n\nFind complete code examples in the [src/testdata/java/samples] folder.\n\n\n\nExecution\n---------\n\nTo run the PojoBuilder annotation processor, include it in your compile-time classpath.\n\nAt runtime, no libraries are needed because PojoBuilder's annotations have a retention policy of `CLASS`.\n\nBelow are brief instructions for running PojoBuilder with:\n* [the javac tool](#using-javac)\n* [Maven](#using-maven)\n* [Gradle](#using-gradle)\n* [Eclipse](#using-eclipse).\n\n### Using Javac\nThe `javac` compiler detects PojoBuilder if `pojobuilder-*.jar` is in the classpath.\n\n\nExample:\n\n    javac -cp pojobuilder-4.3.1-jar-with-dependencies.jar Contact.java\n\nThis generates `ContactBuilder` if `Contact` is annotated with `@GeneratePojoBuilder`.\n\nSee the [javac documentation] for more information.\n\n### Using Maven\n\nAdd the following to your project's `pom.xml`:\n\n\t\u003cdependency\u003e\n\t\t\u003cgroupId\u003enet.karneim\u003c/groupId\u003e\n\t\t\u003cartifactId\u003epojobuilder\u003c/artifactId\u003e\n\t\t\u003cversion\u003e4.3.1\u003c/version\u003e\n\t\t\u003c!-- 'provided' scope because this is only needed during compilation --\u003e\n\t\t\u003cscope\u003eprovided\u003c/scope\u003e\n\t\u003c/dependency\u003e\n\nNotes:\n* The compile phase auto-detects and activates PojoBuilder.\n* Generated sources appear at `${project.build.directory}/generated-sources/annotations`.\n* To keep generated sources in a different directory, configure the `generatedSourcesDirectory` of the `maven-compiler-plugin`. See the [sample Maven pom].\n* For incremental compilation, consider [using the Maven Processor plugin] instead.\n* Eclipse users may install [m2e-apt](https://github.com/jbosstools/m2e-apt) for integrated annotation processing.\n\n### Using Gradle\nThis script shows how to run the PojoBuilder annotation processor with Gradle.\n```groovy\nplugins {\n    id 'java'\n}\n\nrepositories {\n    mavenCentral()\n}\n\ndependencies {\n    annotationProcessor 'net.karneim:pojobuilder:4.3.1'\n    compileOnly 'net.karneim:pojobuilder:4.3.1:annotations'\n}\n```\n\nGenerated sources go to the standard `build/classes` directory.\n\nTo change the destination:\n```groovy\ntasks.compileJava {\n    options.compilerArgs += ['-s', \"$projectDir/src/generated/java\"]\n}\n```\n\nThere is [another Gradle script] that enables PojoBuilder for Eclipse IDE.\n\n### Using Eclipse\nTo run PojoBuilder in Eclipse:\n\n* Open your project's properties dialog\n* Navigate to \"Java Build Path\" tree node\n* Open the \"Libraries\" tab\n* Add `pojobuilder-4.3.1-annotations.jar` to your project classpath\n* Navigate to \"Java Compiler / Annotation Processing\" tree node\n* Check \"Enable project specific settings\"\n* Check \"Enable annotation processing\"\n* Check \"Enable processing in editor\"\n* Specify the target directory for the generated code in \"Generated source directory\"\n* Navigate to \"Java Compiler / Annotation Processing / Factory Path\" tree node\n* Check \"Enable project specific settings\"\n* Click \"Add JARs...\"\n* Add `pojobuiler-4.3.1-jar-with-dependencies.jar`\n* Click \"OK\"\n\nHow To Build\n------------\nTo compile this project's sources, use Gradle (see [build.gradle]).\n\n[Java]: http://www.oracle.com/technetwork/java/\n[generation gap pattern]: http://martinfowler.com/dslCatalog/generationGap.html\n[JavaWriter]: https://github.com/square/javawriter\n[Sonatype OSS Maven Repository]: https://oss.sonatype.org/content/repositories/releases/net/karneim/pojobuilder\n[Maven Central]: http://search.maven.org/#search|ga|1|a%3A%22pojobuilder%22\n[`pojobuilder-4.3.1-jar-with-dependencies.jar`]: https://oss.sonatype.org/content/repositories/releases/net/karneim/pojobuilder/4.3.1/pojobuilder-4.3.1-jar-with-dependencies.jar\n[javac documentation]: http://docs.oracle.com/javase/6/docs/technotes/tools/solaris/javac.html#processing\n[@ConstructorProperties]: http://docs.oracle.com/javase/6/docs/api/java/beans/ConstructorProperties.html\n\n[release history page]: http://github.com/mkarneim/pojobuilder/releases\n[PojoBuilder wiki]: http://github.com/mkarneim/pojobuilder/wiki\n[cookbook]: http://github.com/mkarneim/pojobuilder/wiki/Cookbook\n[another Gradle script]: https://github.com/mkarneim/pojobuilder/wiki/Enabling-PojoBuilder-for-Eclipse-Using-Gradle\n\n[COPYING]: http://github.com/mkarneim/pojobuilder/blob/master/COPYING\n[build.gradle]: http://github.com/mkarneim/pojobuilder/blob/master/build.gradle\n[sample Maven pom]: http://github.com/mkarneim/pojobuilder/wiki/Sample-Maven-Pom\n[using the Maven Processor plugin]: http://github.com/mkarneim/pojobuilder/wiki/Incremental-Compilation-and-Maven\n[sample ANT build script]: http://github.com/mkarneim/pojobuilder/wiki/Sample-Ant-Script\n\n[@GeneratePojoBuilder]: http://github.com/mkarneim/pojobuilder/blob/master/src/main/java/net/karneim/pojobuilder/GeneratePojoBuilder.java\n[@FactoryProperties]: http://github.com/mkarneim/pojobuilder/blob/master/src/main/java/net/karneim/pojobuilder/FactoryProperties.java\n\n[property pattern]: http://github.com/mkarneim/pojobuilder/wiki/Property-Pattern-Examples\n\n[samples]: http://github.com/mkarneim/pojobuilder/tree/master/samples\n[src/testdata/java/samples/dsl/DslTest.java]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/dsl/DslTest.java\n[src/testdata/java/samples]: http://github.com/mkarneim/pojobuilder/tree/master/src/testdata/java/samples\n[`ContactBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/ContactBuilder.java\n[`UserBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/UserBuilder.java\n[`UrlBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/UrlBuilder.java\n[`FileBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/FileBuilder.java\n[`InputSourceFactory.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/InputSourceFactory.java\n[`InputSourceBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/InputSourceBuilder.java\n[`CalendarFactory.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/CalendarFactory.java\n[`GregorianCalendarBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/GregorianCalendarBuilder.java\n[`Player.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/Player.java\n[`PlayerBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/PlayerBuilder.java\n[`AbstractPlayerBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/AbstractPlayerBuilder.java\n[`Address.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/Address.java\n[`AddressBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/AddressBuilder.java\n[`Recipient.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/Recipient.java\n[`RecipientBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/RecipientBuilder.java\n[`Builder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/Builder.java\n[`Recipient.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/Recipient.java\n[`RecipientBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/RecipientBuilder.java\n[`TextEmail.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/TextEmail.java\n[`TextEmailBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/TextEmailBuilder.java\n[`Credentials.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/Credentials.java\n[`CredentialsBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/CredentialsBuilder.java\n[`CredentialsValidator.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/CredentialsValidator.java\n[`Task.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/Task.java\n[`TaskBuilder.java`]: http://github.com/mkarneim/pojobuilder/blob/master/src/testdata/java/samples/TaskBuilder.java\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmkarneim%2Fpojobuilder","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmkarneim%2Fpojobuilder","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmkarneim%2Fpojobuilder/lists"}