What is the visibility of language elements (ie Private vs Public)?

Card Puncher Data Processing

About

The visibility is defined by the private and public keywords where:

  • Private elements are hidden from the outside world.
  • Public elements becomes the API that is accessible from the outside.

Private / Public may be defined on:

Hiding Implementation

A common design pattern is to hide (make private) the most possible element.





Discover More
Card Puncher Data Processing
Code Shipping - (Module|Component)

Module are several source scripts (compiled or not) bundled together as a mean to: group code that can be: reused. The component is then called: a library or package when distributed or a dependency...
Card Puncher Data Processing
Data Type - Interface (Abstract Type)

An interface is language construct that permits to define an abstract types (ADT). The interface element are public (not private) The two terms are often interchangeable. An ADT means an interface and...
Card Puncher Data Processing
Design Pattern - (Static) Factory

The Factory pattern creates an instance of an object according to a given specification, sometimes provided as arguments, sometimes inferred. It's a dependency resolving approach. A factory class decouples...
Java Conceptuel Diagram
How to exclude properties from the JSON output with Jackson?

This article lists the techniques that may be used with the Jackson libary to filter out some properties of an object when transforming it as a JSON. Filter There are 5 techniques that you can apply...
Classes Access
Java - Access Modifier (private, public, )

in Java. Access level modifiers determine whether other classes can use a particular field or invoke a particular method. There are two levels of access control: At the top level: public, or package-private...
Javascript - Module Pattern

This article shows classic design pattern with ECMAScript on how to organize javascript code with a structure that make possible to: get input return output and hide the implementation from the...
Card Puncher Data Processing
Language - Application Programming Interface ( API )

API An Application Programming interface (API) is the set of public element of an module (package, library) The element of an API may be: Classes, Interfaces, Constructor, Members, ......
Card Puncher Data Processing
Object - (Mutator|Setter|Set) method

Mutators are methods. Their role are to set the values of an object's state The usages are: central point of control for the input in order to reject bad data change detection (if the value is not...
Card Puncher Data Processing
The Art of Programming - Information System and Software Design

The Art of Programming - Information System and Software Design This section is about how to use the basic block of a language in order to create high order component. Abstract:_The_Art_of_DesignThe...



Share this page:
Follow us:
Task Runner