Name

javax.microedition.lcdui.TextBox

Synopsis

This class, which extends the Screen class, is a screen that allows the user to enter and edit text. A TextBox object has a title, a default string, a maximum size, and a constraint.

public classTextBox extends Screen {
   // public constructors
   public TextBox(String title, String text, int maxSize, int constraints);
   // public instance methods
   public void delete(int offset, int length);
   public int getCaretPosition(  );
   public int getChars(char[] data);
   public int getConstraints(  );
   public int getMaxSize(  );
   public String getString(  );
   public void insert(char[] data, int offset, int length, int position);
   public void insert(String src, int position);
   public void setChars(char[] data, int offset, int length);
   public void setConstraints(int constraints);
   public int setMaxSize(int maxsize);
   public void setString(String text);
   public int size(  );
}

Get Wireless Java now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.