Zolf
asked on
expalin DefaultMutableTreeNode.getUserObject()
hello there,
Could you anyone tell me what this method does precisely.and when to use it.
DefaultMutableTreeNode.get UserObject ()
cheers
zolf
Could you anyone tell me what this method does precisely.and when to use it.
DefaultMutableTreeNode.get
cheers
zolf
ASKER
Object obj = tree.getLastSelectedPathCo
DefaultMutableTreeNode select = (DefaultMutableTreeNode)ob
System.out.println(select)
Object uObject = select.getUserObject();
System.out.println(uObject
both the statements print the same.so what is the difference
you may want to access some property of the user object
ASKER
for example ??
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
you use it whenever you need to access that object