Begin a New Adventures, with oldest Lineage 2 Community!
What's next? You can create game account. Have fun in the forums!
  • https://forum.lineage2dex.com/threads/16500/

Teh Official OMG WTF thread.

DeuX

He's normal mod, only super mods as me and you can access the moderation tools. Was the same for me before I told Catalin.
 

Shade

He's normal mod, only super mods as me and you can access the moderation tools. Was the same for me before I told Catalin.
Fuck knows who's what. Says "moderator" right under your name so I didn't assume you were a supermeng
 

DeuX

Fuck knows who's what. Says "moderator" right under your name so I didn't assume you were a supermeng
I had super mod also, then it changed to moderator but kept the permissions.
 

Trespasser

Moderator
Is there like any reason to ever use the private keyword for now
It's always great to use the private keyword. Getters and setters allow for easier code debugging. When you'll get to writing bigger apps, you'll see that it's easier to just put a breakpoint in the setter and check where it is being called. Accessors are also useful for (you got it) limiting access but I think you've got that bit figured out by yourself.
 
Last edited:

Shade

It's always great to use the private keyword. Getters and setters allow for easier code debugging. When you'll get to writing bigger apps, you'll see that it's easier to just put a breakpoint in the setter and check where it is being called. Accessors are also useful for (you got it) limiting access but I think you've got that bit figured out by yourself.
english pls
 

BloodyAng3l

Hold your horses bro I'm eating pizza
*drools*

Is there like any reason to ever use the private keyword for now
Usually "private" stands for use only within the scope of this class.
EG: You have a class called DoMath that exposes a method called SumAll. You use a private variable such as:
private int mySum=0;

what's the purpose you may ask. Well calling the SumAll will expose a result, and the mySum variable will store that value, encapsulated within the class and being available only within that class.
 

Shade

Usually "private" stands for use only within the scope of this class.
EG: You have a class called DoMath that exposes a method called SumAll. You use a private variable such as:
private int mySum=0;

what's the purpose you may ask. Well calling the SumAll will expose a result, and the mySum variable will store that value, encapsulated within the class and being available only within that class.
And why would I care if it's only available within the class
 

BloodyAng3l

You can declare private a method or a variable.
Let's take an example where you have the class DoMath which has a method called SquareRoot.
The PUBLIC method SquareRoot has let's say 2 methods that help, DoMath1 and DoMath2. Those 2 methods are used only within the SquareRoot so that we declare them as private.

All in all, the use is to hide the methods/variables that we don;t want to be exposed.

By default, methods and variable are private if you don;t declare them otherwise.
 

Facebook

Discord

Members online

No members online now.
Top