|
Question 1 Which block of code will ensure that a network connection has been closed? (Choose one.) A. Exhibit A B. Exhibit B C. Exhibit C D. Exhibit D E. Exhibit E Answer: A Question 2. Consider the code below: What is a more efficient way of calculating the midpoint? (Choose one.) A. int midpoint = (int) ((double) width) / 2.0; B. int midpoint = Fixed32.div(width, 2); C. int midpoint = (int) (width * 0.5f); D. int midpoint = width >> 1; E. int midpoint = width >> 2; Answer: D Question 3. Which two of the following operations should be avoided on the main event thread? (Choose two.) A. Pushing a screen onto the display stack B. Displaying a Dialog screen C. Performing network communication D. Calling the sleep method E. Capturing of keyboard input Answer: C, D Question 4. A BlackBerry device application collects information about several hundred books. The application needs to sort books by title. Which combination of data structures should be used to manage the objects? (Choose one.) A. net.rim.device.api.util.SimpleSortingVector and net.rim.device.api.util.StringComparator B. java.util.Hashtable and net.rim.device.api.util.StringComparator C. net.rim.device.api.util.StringRepository and net.rim.device.api.util.StringPattern D. java.util.TreeSet and net.rim.device.api.util.StringComparator E. java.util.Stack and net.rim.device.api.util.StringComparator Answer: A Question 5. An application receives notification that a new data object is being saved in the RuntimeStore. It may take up to 60 seconds to save this data. Which method should the application use to obtain the object from the RuntimeStore? (Choose one.) A. get( long objectUID ) B. getInstance() C. fetch( Class objectClass, long timeout ) D. waitFor( long objectUID ) E. put( long objectUID, Object anObject) Answer: D Question 6. The following application is set to auto-run at startup: Which approach would most reliably solve the problem this application will encounter? (Choose one.) A. It should callThread.sleep() for ten seconds before pushing the screen to verify that the BlackBerry device has completed its boot up process B. Threads should be moved to their own standalone class so that they do not cause a security exception C. Theint values in the MenuItem constructor should equal the y MenuString length to leave enough room for the string D. It should use theApplicationManager.inStartup() before pushing the screen to verify that the BlackBerry device has completed its boot up process E. It should use theApplicationManager.inStartup() before pushing the screen to verify that the BlackBerry device has completed its boot up process F. It should use theApplicationManager.inStartup() before pushing the screen to verify that the BlackBerry device has completed its boot up process G. ThemakeMenu method of MainScreen must be overridden to use a menu Answer: D, E, F Question 7. A developer is designing a BlackBerry device application that provides summaries of large amounts of data. The summaries require extensive computations. Which design approach will meet these requirements? (Choose one.) A. Store the full set of data locally on removable media using a compressed format B. Supplement memory available on the BlackBerry device and compute the results locally C. Use URL encodings to expedite the transfer of data between a remote server and the BlackBerry device D. Compute the summary on a remote server and access the results through a BlackBerry Enterprise Server connection E. Use local storage and the floating point processor on the BlackBerry device to speed up computations Answer: B Question 8. A customer needs an application that will store temporary data and expose it to other BlackBerry device applications. Which API will meet this requirement? (Choose one.) A. RuntimeStore B. PersistentStore C. Location Based Services D. Global Events E. Connector Answer: A Question 9. An application requires the creation of a custom field that can display animation. Which class and method combination should be used to accomplish this task? (Choose one.) A. Field.paint(Graphics graphics) B. MainScreen.paint(Graphics graphics) C. Field.subpaint(Graphics graphics) D. Screen.draw(Graphics graphics) E. GameCanvas.paint(Graphics graphics) Answer: A Question 10. Consider the Counter class whose code is below: Assuming that the go() method is always invoked serially, why is a different count printed at the end almost every time that it is invoked? (Choose one.) A. Therun() method is not declared "synchronized" B. The _count variable is not declared "synchronized" C. The ++ operator is not atomic D. The _count variable overflows E. The Counter class is not declared "synchronized" Answer: C Question 11. A developer is writing a game with custom graphics and animations that will need to fit on multiple screen sizes for various BlackBerry devices. The developer needs to minimize the number of images created for the game. Which API will support these requirements? (Choose one.) A. SVG B. Display C. Transition D. Multimedia E. Game Answer: A
Copyright © 2004 CertsBraindumps.com Inc. All rights reserved.