Download Now!Here are your Favorite Software for Mac & Windows!

Test answers for OpenSocial Test 2016

Test answers for opensocial test 2016 available in here,we are easily provide all upwork test answer in here that can be make easy your professional strong profile.
Q.1. You can not send mails to friends by using OpenSocial (v0.7) for Orkut application?

  • True
  • False

Q.2. With the help of the ‘gadgets.io.makeRequest()’  function in OpenSocial API, you can _____.

  • get a user’s profile data
  • get a user’s friend lList
  • delete “Persistence Data”
  • add a user to the friend list.
  • fetch content from other web servers and web pages

Q.3. Which of the following are the valid ContentTypes under ‘gadgets.io.ContentType’ namespace?

  • DOM
  • FEED
  • SCRIPT
  • JSON

Q.4. Arrange in proper sequence how an application gets live in Orkut using OpenSocial (v0.7).(Starting with the 1st)

  1. Submitting the application to orkut
  2. Registration at sandbox
  3. Adding the application in sandbox
  4. Creating an account in orkut
  • 4,1,2,3
  • 4,2,3,1
  • 2,4,3,1
  • 2,3,4,1

Q.5. What is the function of the “gadgets.pubsub” namespace in OpenSocial API (v0.7)?

  • It is used to create feed channels.
  • It is used to publish messages to feed channels
  • It is used to subscribe gadgets to a messaging channel
  • It is used to unsubscribe gadgets from a messaging channel

Q.6. Suppose there is an OpenSocial APT named ‘Messages’ which is integrated with the Google App Engine. Through which of the following API namespaces will OpenSocial app make calls and get data from API hosted on Google App Engine?

  • gadgets.io.MethodType(get)
  • gadgets.io.makeRequest
  • OpenSocial.DataRequest
  • OpenSocial.newDataRequest()

Q.7. Suppose you have chosen to install an OpenSocial API named “Games” in your orkut profile.Which of the following identities is taken by you by installing the application?

  • VIEWER
  • OWNER
  • AUTHOR
  • USER

Q.8. Which statements are incorrect with regard to the implementation of OpenSocial (v0.7)?

  • To implement OpenSocial, you require your own web hosting
  • OpenSocial applications can’t be made private
  • To configure OpenSocial, database is required
  • OpenSocial can be implemented only by using Javascript and XML
  • OpenSocial is a product which requires licensing

Q.9. What is the purpose of the “gadgets.util.escapeString” function?

  • It is used to HTML decode the string.
  • It is used to escape special characters in a string
  • It is used to escape invalid string codes
  • It is used to HTML encode the string

Q.10. Which of the following request is sent to the apiserver when an OpenSocial API wants to call the Google App Engine server for data,?

  • fetch_data
  • get_data
  • get
  • call

Q.11. Which of the following are the constant identifiers in OpenSocial API?

  • OWNER
  • VIEWER
  • USERS
  • VIEWER_FRIENDS

Q.Q.12. What is the function of the “makerequest()” method in OpenSocial API (v0.7)?

  • It is used to add new content by the user
  • It is used to fetch content from other remote web servers and web pages
  • It is used to make a request for adding the specific application
  • It is used to make a request for accessing some particular application

Q.13. Which of the following are the supported keys for the Url.getField() method.?

  • ADDRESS
  • LINK_TEXT
  • TYPE
  • Referrer

Q.14. You can embed flash objects with OpenSocial (v0.7).

  • True
  • False

Q.15. You want to build an OpenSocial API, and you want to configure the API to be run on version 0.7? Which of the following statements is the correct configuration?

  • <EnumValue feature=”OpenSocial-0.7″ />
  • <Require feature=”OpenSocial-0.7″ />
  • < EnumValue version=”OpenSocial-0.7″ />
  • <Require version=”OpenSocial-0.7″ />

Q.16. Which of the following methods are defined under “OpenSocial.Permission” namespace?

  • OpenSocial.hasPermission()
  • OpenSocial.Permission.VIEWER
  • OpenSocial.requestPermission()
  • OpenSocial.getPermission()

Q.17. You have an OpenSocial API. You want to show the same OpenSocial API content in both ‘profile’ view and ‘canvas’ view. Which of the following is the correct code?

  • <Content type=”html” view=”(profile , canvas)”>
  • <Content type=”html” view=”all”>
  • <Content type=”html” view=”profile,canvas”>
  • Any of the above can be used.

Q.18. Consider the following code for OpenSocial application (v0.7) for Orkut?

 

http://sandbox.orkut.com/Application.aspx?appId=xxxxxxxxxxxx&appParams=%7B%20%22hello%22%20%3A%20%22hi%22%20%7D

 

If the above mentioned url is passed and processed by the following code, what will be the value of “getOutput”?

 

var querydata = gadgets.views.getParams();

var getOutput = querydata[“hello”];

  • hello
  • hi
  • hello and hi
  • hi and hello
  • It will produce an empty string

Q.19. In the process of integrating OpenSocial API with Google App Engine, you do not need to maintain any servers.

  • True
  • False

Q.20. Which of the following ‘DataRequest’ methods will be used in order to read, write and clear data from Persistence API?

  • newFetchPersonRequest(idSpec, opt_params)
  • newFetchPersonAppDataRequest(idSpec, keys)
  • newFetchPeopleRequest(idSpec, opt_params)
  • newUpdatePersonAppDataRequest(id, key, value)

Q.21. You have made a function named ‘getfriends()’, which will get the list of friends once the OpenSocial API is loaded. Which of the following event handler will call this function after the API has been loaded?

  • gadgets.util.registerOnLoadHandler(getfriends);
  • gadgets.io.makeRequest.getfriends();
  • gadgets.util.registerOnLoadHandler.getfriends();
  • gadgets.io.makeRequest(getfriends);

Q.22. What do you mean by “Activity” in OpenSocial API (v0.7)?

  • Action performed by a user
  • Addition of a new user
  • Deletion of an existing user
  • Moderation of users
  • None of the above

Q.23. Which of the following type conventions are used in OpenSocial Gadgets API?

  • Array<T>
  • var
  • string
  • Map.<K, V>
  • int

Q.24. In RESTful Data API, the server interactions are handled by _______ protocol and the Authentication is handled by _____.

  • HTTPS, OAuth
  • AtomPub, BBAuth
  • HTTPS, BBAuth
  • AtomPub, OAuth

Q.25. Which of the following languages are used for integrating OpenSocial API with

Google App Engine?

  • Javascript
  • HTML
  • C++
  • JSON
  • Python

Q.26. Which of the following are the valid RequestParameters under ‘gadgets.io. Parameters’ namespace?

  • POST_DATA
  • GET_DATA
  • CONTENT_TYPE
  • SET_DATA

Q.27. If you want to handle the error of maximum usage of “Quotas” in OpenSocial (v0.7), which object field of the class “OpenSocial.ResponseItem.Error” will be used to handle the error?

  • BAD_REQUEST
  • FORBIDDEN
  • INTERNAL_ERROR
  • NOT_IMPLEMENTED
  • UNAUTHORIZED

Q.28. Which of the following namespaces are included in OpenSocial JavaScript API (v0.7)?

  • OpenSocial-0.7.*
  • MyOpenSpace.*
  • OpenSocial.*
  • gadgets.*

Q.29. In OpenSocial API, the “gadgets.Prefs” namespace enables the end user to _____.

  • set preferences of the OpenSocial API
  • set OpenSocial API module dimensions
  • handle messages in API
  • set Permissions of the API

Q.30. Which of the following are authorizations of API  supported Gadgets in OpenSocial API (v0.7)?

  • gadgets.io.AuthorizationType.AUTHENTICATED
  • gadgets.io.AuthorizationType.SIGNED
  • gadgets.io.AuthorizationType.WEB
  • gadgets.io.AuthorizationType.FORM
  • gadgets.io.AuthorizationType.NONE

Q.31. Which of the following user general profile fields cannot be accessed in orkut applications for OpenSocial (v0.7)?

  • Birthday
  • Zipcode
  • Birthyear
  • Relationship status
  • Latitude/Longitude

Q.32. Which  of the following elements are present under <ModulePrefs > tag?

  • <Require>
  • <script>
  • <Body>
  • <Optional>
  • <Locale>

Q.33. What is the fuctionallity of the “gadgets.MiniMessage” class in OpenSocial (v0.7)?

  • To create messages that will appear to the user within the gadget
  • To create messages which are being displayed on the main menu
  • To create messages which are used to send emails to friends
  • To create messages to access data from other web servers

Q.34. What does <ModulePrefs> section specify in OpenSocial (v0.7)?

  • Characteristics of the gadget
  • Controls that allow the users to specify settings for the gadget
  • Programming logic of the gadget
  • Language used in the gadget

Q.35. What will happen if “&bpc=1” is appended to an orkut application canvas page url as querystring?

  • It will retain the cache of the page
  • It will load a fresh copy of the page
  • It will create cookies for the specific page
  • It will create language specific views for the page

Q.36. When you add an application to orkut sandbox by using OpenSocial (v0.7), which of the following types of users can add the application?

  • Orkut users with sandbox access
  • The application creator and his friends
  • Any orkut user
  • None of the above

Q.37. Suppose you have an OpenSocial API with the name “message.xml”. You have integrated the API with the Google App Engine. The Google App Engine has the configuration file named “app.yaml”. Now you want to handle the request generated by the OpenSocial API to the Google APP Engine? Which file will you configure in order to handle the request?

  • message.xml
  • app.yaml
  • Both these files will be configured
  • There is no need for configuration

Q.38. Which of the following are the supported keys for the Person.getField() method.?

  • ABOUT_ME
  • NICKNAME
  • LIKES
  • TURN_OFFS

Q.39. What is the functionality of the “getdomain” method in the Environment class in OpenSocial API (v0.7)?

  • It displays the url of application
  • It gives the current site on which the application is running
  • It gives information about the gadget url and the language used
  • All of the above

Q.40. IN OpenSocial, errors are returned through ‘OpenSocial.ResponseItem.Error’ namespace. Which of the following is not an error code?

  • NOT_FOUND
  • NOT_IMPLEMENTED
  • INTERNAL_ERROR
  • UNAUTHORIZED

Q.41. You have done a lot of testing in your OpenSocial API and now you want to delete all the “Persistence Data”. The following method is used to clear the data:

 

var req = OpenSocial.newDataRequest();

req.add(

req.newUpdatePersonAppDataRequest

(OpenSocial.DataRequest.PersonId.VIEWER, –, –), “set_data”);

req.send(set_callback);

 

The above command has some arguments missing at –. Which of the following set of arguments will complete the above command?

  • all, null
  • *, null
  • *, clear
  • all, clear

Q.42. Some of the classes and methods in the ‘gadget.*’ namespace are feature-specific.

In which of the following tags must the'<Require feature=”foo”/>’ element be included in order to use them?

  • <Content>
  • <Module>
  • <![CDATA[]]>
  • <ModulePrefs>

Q.43. Persistence API provides a storage mechanism to save and load data. In which form is the data stored?

  • It is stored in the form of data objects
  • It is stored in the form of XML
  • It is stored in the form of encrypted codes
  • It is stored in the form of key/value pairs

Q.44. Which of the following are the components of the OpenSocial API (v0.7)?

  • JavaScript API
  • Gadgets
  • Google App Code
  • RESTful API

Q.45. Which of the following objects are defined in the ‘add’ method, under  ‘OpenSocial.DataRequest’ namespace?

  • newFetchPersonActivitiesRequest(idSpec, opt_params)
  • newFetchPeopleRequest(idSpec, opt_params)
  • newFetchPersonAppDataRequest(idSpec, keys)
  • newUpdatePersonAppDataRequest(id, key, value)

Q.46. If the content is a feed and you want to fetch the number of entries in OpenSocial (v0.7), which object field of class “gadgets.io.RequestParameters” will be used?

  • AUTHORIZATION
  • CONTENT_TYPE
  • GET_SUMMARIES
  • HEADERS
  • METHOD
  • NUM_ENTRIES
  • POST_DATA

Q.47. You have a collection of multiple objects and you want to retrieve the size of that collection. Which of the following methods will you use in order to calculate the collection size?

  • getTotalSize()
  • size()
  • getCollectionSize()
  • getsize()

Q.48. In OpenSocial API, “OpenSocial.IdSpec.Field” namespace is used _____.

  • to get the groupid of the user
  • to get the titleid of the message in message template
  • to get the userid of the user
  • to get the network distance between two users

Q.49. Which of the following Content Type Requests are handled by the

gadgets.io.makeRequest(url, callback, opt_params)

method?

  • Text Requests
  • DOM Requests
  • HTTP Requests
  • JSON Requests
  • FEED Requests

Q.50. What will the following code fetch for variable “xyz” in OpenSocial for Orkut?

Var xyz=gadgets.util.getUrlParameters()[“gadgetId”];

  • Current User ID
  • Owner User ID
  • Application ID
  • View ID

Q.51. In Persistence API, the data store only accepts strings for storage, which means that you must convert complex data structures to strings before saving them. Which of the following functions is used to convert JavaScript objects and arrays to a string value?

  • gadgets.json.stringify
  • gadgets.io.stringify
  • gadgets.io.encodeValues
  • gadgets.io.text

Q.52. Which of the following are compulsory for creating an OpenSocial (v0.7) application for Orkut?

  • Orkut ID
  • Sandbox access
  • Goggle page hosting
  • Text editor
  • Database access

Q.53. What is shown in “Activity Stream” in an Orkut application using OpenSocial (v0.7)?

  • Newly added application in orkut
  • Newly added themes in orkut
  • Recently added community
  • Updates of friends

Q.54. What kind of data can be saved and retrieved in OpenSocial API (v0.7)?

  • per-user
  • global application
  • per-application
  • per-application instance

Q.55. You have created an OpenSocial API  “test.xml” and integrated it into Google App Engine. You don’t want just anybody to be able to access your application data through the “test.xml” API. What should you do in order to restrict access to the users?

  • Add permissions on the API xml file
  • Add Digital signatures to the API xml file
  • Add username and password to the API xml file
  • You cannot do it as it is a Javascript and HTML supported API

Q.56. Which of the following Roles are defined in OpenSocial API (v0.7)?

  • Viewer
  • Owner
  • Moderator
  • Friend
  • Admin

Comments

comments