• About Us
  • Privacy Policy
  • Disclaimer
  • Contact Us
AimactGrow
  • Home
  • Technology
  • AI
  • SEO
  • Coding
  • Gaming
  • Cybersecurity
  • Digital marketing
No Result
View All Result
  • Home
  • Technology
  • AI
  • SEO
  • Coding
  • Gaming
  • Cybersecurity
  • Digital marketing
No Result
View All Result
AimactGrow
No Result
View All Result

A easy instance configuration to generate package deal non-public jOOQ code

Admin by Admin
April 24, 2025
Home Coding
Share on FacebookShare on Twitter


Java’s package deal non-public visibility is an underrated characteristic. Whenever you omit any visibility modifier in Java, then the default (for many objects) is package deal non-public, i.e. the article is seen solely to sorts in the identical package deal:

class YouDontSeeMe {}
class YouDontSeeMeEither {}

The truth is, a compilation unit (the .java file) can comprise a number of such courses. You don’t must create a file per package deal non-public sort. You might even put all of those sorts in your package-info.java file, it doesn’t matter.

When utilizing jOOQ’s code generator, issues are generated as public sorts per default, as you’re possible going to make use of this generated code in every single place. You may nonetheless prohibit entry utilizing Java 9’s module system if you need.

However sometimes, even with jOOQ generated code, package deal non-public visibility may be helpful, if some knowledge entry package deal desires to cover its implementation particulars from different packages within the module.

Right here’s an instance code era configuration to make this occur:


  
    
      com.instance.codegen.SinglePackageStrategy

      
      
      
    

    

      
      NONE
    

    
      com.instance

      
      false
    
  

That wasn’t too onerous? Utilizing this strategy, you may make sure that your jOOQ generated code by no means leaks into any consumer code that shouldn’t see jOOQ sorts.

Like this:

Like Loading…

Printed by lukaseder

I made jOOQ
View all posts by lukaseder

Tags: CodeconfigurationGeneratejOOQPackagePrivateSimple
Admin

Admin

Next Post
8 Greatest Curly Haired Anime Characters

8 Greatest Curly Haired Anime Characters

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Recommended.

Lumai Raises $10M+ to Revolutionize AI Compute with Optical Processing

Lumai Raises $10M+ to Revolutionize AI Compute with Optical Processing

April 3, 2025
Palantir indicators a cope with The Nuclear Firm beneath which the startup can pay Palantir $100M over 5 years to develop AI software program for the nuclear business (Miquela Thornton/Bloomberg)

Palantir indicators a cope with The Nuclear Firm beneath which the startup can pay Palantir $100M over 5 years to develop AI software program for the nuclear business (Miquela Thornton/Bloomberg)

June 27, 2025

Trending.

How you can open the Antechamber and all lever places in Blue Prince

How you can open the Antechamber and all lever places in Blue Prince

April 14, 2025
ManageEngine Trade Reporter Plus Vulnerability Allows Distant Code Execution

ManageEngine Trade Reporter Plus Vulnerability Allows Distant Code Execution

June 10, 2025
Expedition 33 Guides, Codex, and Construct Planner

Expedition 33 Guides, Codex, and Construct Planner

April 26, 2025
Important SAP Exploit, AI-Powered Phishing, Main Breaches, New CVEs & Extra

Important SAP Exploit, AI-Powered Phishing, Main Breaches, New CVEs & Extra

April 28, 2025
7 Finest EOR Platforms for Software program Firms in 2025

7 Finest EOR Platforms for Software program Firms in 2025

June 18, 2025

AimactGrow

Welcome to AimactGrow, your ultimate source for all things technology! Our mission is to provide insightful, up-to-date content on the latest advancements in technology, coding, gaming, digital marketing, SEO, cybersecurity, and artificial intelligence (AI).

Categories

  • AI
  • Coding
  • Cybersecurity
  • Digital marketing
  • Gaming
  • SEO
  • Technology

Recent News

The Obtain: How fertility tech is altering households, and Trump’s newest tariffs

The Obtain: How fertility tech is altering households, and Trump’s newest tariffs

August 3, 2025
New Assault Makes use of Home windows Shortcut Information to Set up REMCOS Backdoor

New Assault Makes use of Home windows Shortcut Information to Set up REMCOS Backdoor

August 3, 2025
  • About Us
  • Privacy Policy
  • Disclaimer
  • Contact Us

© 2025 https://blog.aimactgrow.com/ - All Rights Reserved

No Result
View All Result
  • Home
  • Technology
  • AI
  • SEO
  • Coding
  • Gaming
  • Cybersecurity
  • Digital marketing

© 2025 https://blog.aimactgrow.com/ - All Rights Reserved