Oracle Java Mobile Edition 1 Mobile Application Developer Certified Professional - 1Z0-869 Exam Practice Test

Which four are direct subclasses of Screen? (Choose four.)
Correct Answer: B,D,E,G Vote an answer
Given the MIDlet code:
11. DatagramConnection dgc
(DatagramConnection)Connector.open("datagram://:444");
1 2. Datagram datagram = dgc.newDatagram(20);
1 3. dgc.receive(datagram);
1 4. byte[] data = datagram.getData();
1 5. String s = new String(data);
1 6. list.append(s, null);
1 7. System.out.println("Datagram received: " + s);
Which two are true regarding the portability of the code between devices? (Choose two.)
Correct Answer: B,D Vote an answer
Which guarantees the application can be installed without push registration conflicts?
Correct Answer: C Vote an answer
Which three functions are performed during the preverification process? (Choose three.)
Correct Answer: B,C,E Vote an answer
What is the minimum number of received SMS messages that a JTWI device must be able to concatenate?
Correct Answer: A Vote an answer
Given:
A record store has three records: Record 1 contains Apple, Record 2 contains Mango, Record 3 contains Cherry, and the RecordComparator class:
1 . public class CompareTest implements RecordComparator {
2 . public int compare(byte[] rec1, byte[] rec2) {
3 . String str1 = new String(rec1), str2 = new String(rec2);
4 . int result = str2.compareTo(str1);
5 . if (result == 0)
6 . return RecordComparator.EQUIVALENT;
7 . else if (result < 0)
8 . return RecordComparator.PRECEDES;
9 . else
1 0. return RecordComparator.FOLLOWS;
1 1. }
1 2. }
What is the return order of the records for an enumerator using CompareTest?
Correct Answer: F Vote an answer
DRAG DROP
Click the Task button.
Given:
9 . Player p = Manager.createPlayer("http://webserver/music.mp3");
1 0. p.setLoopCount(5);
1 1. p.start();
1 2. p.stop();
1 3. p.close();
What is the order of the states that the Player goes through?
Correct Answer:
Which is true regarding access of the manifest file in a MIDlet suite's JAR file?
Correct Answer: D Vote an answer
Given:
1 5. String addr = "sms://+14155557296";
1 6. MessageConnection conn
1 7. = (MessageConnection) Connector.open(addr);
1 8. // insert code here
1 9. message.setPayloadData(imageBytes);
Assume imageBytes is a valid byte array.
Which statement, inserted at line 18, causes the rest of the code fragment to compile correctly?
Correct Answer: D Vote an answer
Assume a particular JTWI phone supports server socket connections. A MIDlet running on the phone attempts to register a connection using:
PushRegistry.registerConnection(connection, midlet, filter); Assume connection, midlet, and filter are NOT null. The statement is executed and throws a ConnectionNotFoundException. What causes the exception?
Correct Answer: B Vote an answer
A MIDlet makes its only attempt to register a push connection on a JTWI device using:
PushRegistry.registerConnection(
"datagram://:79", midlet, "10.0.0.???");
Which is true?
Correct Answer: B Vote an answer
Click the Exhibit button.
Given:
The MIDlet is executed.
The MIDlet is paused and resumed two times.
What is the result?
Correct Answer: D Vote an answer
Given:
1 . import javax.microedition.midlet.*;
2 . public class Foo extends MIDlet {
3 . public void go() {
4 . try {
5 . doStuff();
6 . } catch(java.lang.NoClassDefFoundError e) { }
7 . }
8 . void doStuff() { }
9 . public void destroyApp(boolean b) { }
1 0. public void pauseApp() { }
1 1. public void startApp() {go();}
1 2. }
Assuming the application is targeted for CLDC 1.1, what is the result?
Correct Answer: A Vote an answer
Given:
30. public boolean X(byte[] Y) throws IllegalArgumentException {
31. ByteArrayInputStream bais = new ByteArrayInputStream(arg);
32. DataInputStream dis = new DataInputStream(bais);
33. String type = null; 34. try {type = dis.readUTF();}
3 5. catch (Exception e) { }
3 6. return(Z);
3 7. }
Which substitutions for X, Y, and Z in the code create a valid implementation of RecordFilter that matches records whose type is NOT deleted?
Correct Answer: A Vote an answer
Which two guarantee a wireless message will be removed from the incoming message buffer by the Application Management Software? (Choose two.)
Correct Answer: B,D Vote an answer