• Post Reply Bookmark Topic Watch Topic
  • New Topic

inherting classes avalibile i jar  RSS feed

 
ciju madathil
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

i want to extend the VTextField(basic Forms text item) to implement the functionality (like invalidcharacters, grouping characters in a string like 22-333-444 etc)of javax.swing.text.MaskFormatter.
Can anyone please help me achving this.
Since Java class cannot extend 2 classes.
solution for multiple inheritance is implementing interfaces but since the classes are already present in jar(oracle.forms.ui.VTextField and javax.swing.text.MaskFormatter)
how can i achive this.

Please help me.

Thanks and Regards,
Ciju George
 
Rob Spoor
Sheriff
Posts: 21135
87
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try composition - give the text field a formatter as a field with a getter for it.
 
K Abhijit
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@Rob I doubt whether it would work
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!