This week's book giveaway is in the Design forum.
We're giving away four copies of Building Microservices and have Sam Newman on-line!
See this thread for details.
The moose likes Java in General and the fly likes class A uses class B Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Building Microservices this week in the Design forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "class A uses class B" Watch "class A uses class B" New topic

class A uses class B

Simon Xu
Ranch Hand

Joined: Aug 16, 2000
Posts: 235
There are several cases for "class A uses B". My question is there are any other cases besides the following cases? Thanks.
1) if class A refers to class B as a data member, local
variable, argument, data cast, or if A inherits from B or if
A implements interface B, then A uses B. Classes A and B
interact if either A uses B or B uses A.
2)A can direct refer class B's static methods (or data members). B does not have to be a data member or local variable or argument of A
3)Inner class: if A is an inner class of B, then objects that are instances of A generally retain the ability to access the members of outer class B. In this case, B does not have to be the data member etc of A
4) Anonymous class
Simon Xu
Ranch Hand

Joined: Aug 16, 2000
Posts: 235
hi java Experts,
Can you please spend a few minutes to give me some input? Thanks.
Have you checked out Aspose?
subject: class A uses class B
It's not a secret anymore!