250+ TOP MCQs on Handling Security in Views and Domain object security and Answers

Java Spring Multiple Choice Questions & Answers (MCQs) on “Handling Security in Views and Domain object security”.

1. Element used to secure methods.
a) security:intercept-methods
b) global-method-security
c) all of the mentioned
d) none of the mentioned
Answer: c
Clarification: First, you can embed a security:intercept-methods element in a bean definition to secure its methods. Alternatively, you can configure a global global-method-security element to secure multiple methods.

2. @Secured annotation is used to secure methods implemented by beans.
a) True
b) False
Answer: a
Clarification: You can also annotate methods declared in a bean interface or an implementation class with the @Secured annotation and then enable security for them in global-method-security.

3 Element used to specify access attributes for bean’s methods.
a) security:protect
b) security:intercept
c) security:intercept-security
d) none of the mentioned
Answer: a
Clarification: In a bean’s security:intercept-methods, you can specify multiple security:protect elements to specify access attributes for this bean’s methods.

4. Attribute used to specify custom access decision manager.
a) access-decision-manager-ref
b) access-decision-ref
c) access-decision
d) none of the mentioned
Answer: a
Clarification: If you would like to use a custom access decision manager, you can specify it in the access-decision-manager-ref.

5. JSP technology is also used to handle security of JSP views.
a) True
b) False
Answer: a
Clarification: Spring Security provides a JSPtag library for you to handle security in JSP views.

6. Tag which displays user’s Authentication object.
a) security:tag
b) security_Tag
c) security:authentication
d) none of the mentioned
Answer: c
Clarification: The security:authentication tag exposes the current user’s Authentication object for you to render its properties.

7. Tag which renders the granted authorities one by one.
a) c:for
b) c:forEach
c) c:doWhile
d) c:while
Answer: b
Clarification: You can store the authorities property, which contains the authorities granted to the user, in the JSP variable authorities, and render them one by one with a c:forEach tag.

8. Tag used to render view contents conditionally.
a) security:authorize
b) security:authority
c) security:authenticate
d) none of the mentioned
Answer: a
Clarification: If you would like to render view contents conditionally according to a user’s authorities, you can use the security:authorize tag.

9. Attribute used to render enclosed content.
a) ifGranted
b) if_Granted
c) ifAllGranted
d) none of the mentioned
Answer: c
Clarification: If you want the enclosing content to be rendered only when the user has been granted certain authorities at the same time, you have to specify them in the ifAllGranted attribute.

10. Module that allows each domain to have it’s own access.
a) access share list
b) access common list
c) access control list
d) access list
Answer: c
Clarification: Spring Security provides a module named ACL that allows each domain object to have its own access control list (ACL).

11. ACL(Access control list) consists of:-
a) object identity
b) access control entities
c) none of the mentioned
d) all of the mentioned
Answer: a
Clarification: An ACL contains a domain object’s object identity to associate with the object, and also holds multiple access control entries (ACEs).

12. ACEs(Access control entries) core consists of:-
a) Permissions
b) Security Identity
c) All of the mentioned
d) None of the mentioned
Answer: c
Clarification: Multiple access control entries (ACEs), each of which contains the above mentioned two core parts.

13. Which of the following is/are part of BasePermission class:-
a) CREATE
b) READ/WRITE
c) DELETE
d) All of the mentioned
Answer: d
Clarification: The BasePermission class predefines five basic permissions as constant values for you to use: READ (bit 0 or integer 1), WRITE (bit 1 or integer 2), CREATE (bit 2 or integer 4), DELETE (bit 3 or integer 8), and ADMINISTRATION (bit 4 or integer 16).

14. SID(Security Identity) associates with permission using.
a) principal(PrincipalSid)
b) authority (GrantedAuthoritySid)
c) all of the mentioned
d) none of the mentioned
Answer: c
Clarification: Each ACE contains permissions for a particular SID. An SID can be a principal (PrincipalSid) or an authority (GrantedAuthoritySid) to associate with permissions.

15. Interfaces that defines operation of an ACL service.
a) AclService
b) MutableAclService
c) All of the mentioned
d) None of the mentioned
Answer: c
Clarification: In Spring Security, there are two interfaces that define operations of an ACL service: AclService and MutableAclService. AclService defines operations for you to read ACLs.

250+ TOP MCQs on Logging and Unit Testing and Answers

Java Spring Multiple Choice Questions & Answers (MCQs) on “Logging and Unit Testing”.

1. To perform its logging operations.
a) Log4J
b) LogingJ
c) JLog
d) None of the mentioned
Answer: a
Clarification: Grails relies on Java Log4J to perform its logging operations.

2. Log4J configuration parameters are specified inside:-
a) Config.groovy
b) Conf.groovy
c) Log.groovy
d) None of the mentioned
Answer: a
Clarification: Log4J configuration parameters are specified inside the Config.groovy file.

3. Grails application logging can be configured using:-
a) creating custom appenders
b) logging levels
c) console output
d) all of the mentioned
Answer: d
Clarification: Given Log4J’s logging versatility, a Grails application logging can be configured in various ways. This includes creating custom appenders, logging levels, console output, logging by artifacts and custom logging layouts.

4. Any logging operation occurring at any of the cited packages will be logged.
a) True
b) False
Answer: a
Clarification: The notation follows the convention logging level ‘package name’. This implies that any logging operation occurring at any of the cited packages will be logged so long as it occurs within the specified logging level or a more severe level.

5. In Log4J parlance, each package is known as:-
a) parlance
b) logger
c) all of the mentioned
d) none of the mentioned
Answer: b
Clarification: In Log4J parlance, each package is known as a logger.

6. Log4J also has the following logging level:-
a) fatal
b) error
c) warning
d) all of the mentioned
Answer: d
Clarification: Log4J also has the following logging levels:
fatal, error, warn, info, debug, and trace. fatal is the most severe.

7. By default, all logging message are sent to the stacktrace.groovy file.
a) True
b) False
Answer: a
Clarification: By default, all logging message are sent to the stacktrace.log file located under an application’s root directory.

8. To offer versatile logging functionality:-
a) loggers
b) appenders
c) all of the mentioned
d) none of the mentioned
Answer: c
Clarification: Log4J relies on appenders and loggers to offer versatile logging functionality.

9. A location where logging information is sent.
a) appender
b) logger
c) all of the mentioned
d) none of the mentioned
Answer: a
Clarification: An appender is a location where logging information is sent (e.g., a file or standard output).

10. A location where logging information is generated.
a) appender
b) logger
c) all of the mentioned
d) none of the mentioned
Answer: b
Clarification: A logger is a location where logging information is generated (e.g., a class or package).

11. The default Log4J logger can be customized in a Grails application.
a) True
b) False
Answer: a
Clarification: The default Log4J logger can be customized in a Grails application using the following statement within the log4j { } section of an application’s Config.groovy file:
root {
error()
additivity = true
}

12. An appender that logs to a JDBC connection.
a) jdbc
b) console
c) file
d) rollingFile
Answer: a
Clarification: There are four types of appenders available by default:
• jdbc : An appender that logs to a JDBC connection
• console: An appender that logs to standard output
• file: An appender that logs to a file.
• rollingFile: An appender that logs to a rolling set of files

13. Command for running tests in Grails.
a) grails test-app
b) grails test
c) grails test-app domain class
d) none of the mentioned
Answer: a
Clarification: Running tests in Grails is as simple as executing the grails test-app command from an application’s root directory.

14. Unit tests are designed to validate the logic contained in a single domain class.
a) True
b) False
Answer: a
Clarification: Because of this fact, besides automating the execution of such tests, Grails provides no type of bootstrapping properties for performing these type of tests.

15. Method creates a mock object from a domain class.
a) mockForConstraintsTests
b) mockForConstraints
c) all of the mentioned
d) none of the mentioned
Answer: a
Clarification: This method creates a mock object from a domain class that is used to access a class’s dynamic methods (e.g., validate) needed to perform unit tests.

250+ TOP MCQs on SOAP Web Service and Answers

Java Spring Multiple Choice Questions & Answers (MCQs) on “SOAP Web Service”.

1. A web service contract is described using :-
a) Web Services Description Language
b) Web Services Description
c) All of the mentioned
d) None of the mentioned
Answer: a
Clarification: In contract-last, you expose an existing service interface as a web service whose service contract is generated automatically.

2. There are two approaches to developing a web service, depending on whether you define the contract first or last.
a) True
b) False
Answer: a
Clarification: A web service contract is described using Web Services Description Language (WSDL). In contract-last, you expose an existing service interface as a web service whose service contract is generated automatically. In contract-first, you design the service contract in terms of XML and then write code to fulfill it.

3. In contrast, the contract-first approach encourages you to think of the service contract first in terms of :-
a) XML
b) XML Schema(.xsd)
c) WSDL
d) All of the mentioned
Answer: d
Clarification: In contrast, the contract-first approach encourages you to think of the service contract first, in terms of XML, using XML schema (.xsd) and WSDL.

4. In some cases, it’s also hard to map an object to XML (e.g., an object graph with cyclic references) because there’s actually an impedance mismatch between an object model and an XML model.
a) True
b) False
Answer: a
Clarification: Just like that between an object model and a relational model.

5. Service exporters that can export a bean as a remote service based on the :-
a) RMI
b) Hessian
c) Burlap
d) All of the mentioned
Answer: d
Clarification: Spring comes with several service exporters that can export a bean as a remote service based on the RMI, Hessian, Burlap, or HTTP Invoker remoting technologies.

6. Spring comes with a service exporter that can export a bean as a SOAP web service.
a) True
b) False
Answer: b
Clarification: Spring doesn’t come with a service exporter that can export a bean as a SOAP web service. We will use Apache CXF, which is the de facto successor to XFire.

7. The standard for deploying web services on the Java EE platform as of Java EE 1.4:-
a) JAX-RPC
b) JAX
c) RPC
d) None of the mentioned
Answer: a
Clarification: The standard for deploying web services on the Java EE platform as of Java EE 1.4 was called JAX-RPC. It supported SOAP 1.0 and 1.1, but didn’t support message-oriented web services.

8. To send objects across the wire, beans need to be encoded using the Java Architecture for XML Binding (JAXB).
a) True
b) False
Answer: a
Clarification: JAXB supports many class types out of the box with no special support.

9. If you are deploying into a Java EE 5 (or better) container, you may simply create a bean that is annotated with:-
a) javax.jws.WebService
b) javax.jws.WebServiceProvider
c) all of the mentioned
d) none of the mentioned
Answer: c
Clarification: If you are deploying into a Java EE 5 (or better) container, you may simply create a bean that is annotated with javax.jws.WebService or javax.jws.WebServiceProvider and deploy that into a container in your web application.

10. If you are using the JAX-RS Reference Implementation, this intermediary step will involve a tool called wsgen.
a) True
b) False
Answer: a
Clarification: It will generate the configuration (a file called sun-jaxws.xml) and wrapper beans required to expose your service.

11. Spring provides a factory that can export beans annotated with:-
a) javax.jws.WebService
b) javax.jws.WebServiceProvider
c) all of the mentioned
d) none of the mentioned
Answer: c
Clarification: Spring provides a factory that can export beans annotated with javax.jws.WebService or javax.jws.WebServiceProvider inside the Spring context and then publishes the services using the JAX-WS runtime.

12. Exposing a stand-alone SOAP endpoint using the:-
a) SimpleJaxWsServiceExporter
b) JAX-WS
c) All of the mentioned
d) None of the mentioned
Answer: c
Clarification: Exposing a stand-alone SOAP endpoint using the SimpleJaxWsServiceExporter or the support for JAX-WS in a Java EE container in conjunction with Spring is simple, but these solutions ignore the largest cross-section of developers—people developing on Tomcat.

13. Tomcat doesn’t support JAX-WS by itself.
a) True
b) False
Answer: a
Clarification: Tomcat doesn’t support JAX-WS by itself, so we need to help it by embedding a JAX-WS runtime. There are many choices, and you’re free to take your pick. Two popular choices are Axis2 and CXF, both of which are Apache projects.

14. CXF represents the consolidation of the Celtix and XFire projects, which each had useful SOAP support.
a) True
b) False
Answer: a
Clarification: For our example, we’ll embed CXF since it’s robust, fairly well tested, and provides support for other important standards like JAX-RS, the API for REST-ful endpoints.

15. Factory to use our Spring bean as the implementation:-
a) jaxws:end
b) jaxws:endpoint
c) all of the mentioned
d) none of the mentioned
Answer: b
Clarification: We tell the jaxws:endpoint factory to use our Spring bean as the implementation. We tell it at what address to publish the service using the address element.

250+ TOP MCQs on Workflow Models and jBPM and Answers

Java Spring Aptitude Test on “Workflow Models and jBPM”.

1. A workflow system extricates that process state from the domain and into a separate layer, called a business process.
a) True
b) False

Answer: a
Clarification: A workflow system also typically models which agents in the system do what work, providing work lists for different agents in the system.

2. A workflow engine lets you model the process in a higher-level form:-
a) XML
b) Use Case
c) UML
d) All of the mentioned

Answer: c
Clarification: A workflow engine lets you model the process in a higher-level form, roughly corresponding in code to what a UML activity diagram can describe.

3. A language that, when deployed to a BPEL container, describes the execution of a process.
a) WS-BPEL (BPEL 2.0)
b) WS-BPEL (BPEL)
c) WS-BPEL for People (BPEL4People)
d) Business Process Modeling Notation (BPMN)

Answer: b
Clarification: It interfaces with the outside world via the invocation of external web services. This language describes the runtime behavior of a process.

4. The main feature common to traditional workflow systems is the ability to support work lists for actors in a process.
a) WS-BPEL (BPEL 2.0)
b) WS-BPEL (BPEL)
c) WS-BPEL for People (BPEL4People)
d) Business Process Modeling Notation (BPMN)

Answer: a
Clarification: BPEL had no such support, as it didn’t support human tasks (that is, wait states for people). This specification addresses that exact shortcoming.

5. This provides a set of diagramming notations that describe a business process. This notation is akin to UML activity diagram.
a) WS-BPEL (BPEL 2.0)
b) WS-BPEL (BPEL)
c) WS-BPEL for People (BPEL4People)
d) Business Process Modeling Notation (BPMN)

Answer: d
Clarification: The notation is sometimes ambiguous, however, and one of the formidable challenges facing BPM vendors is creating a drawing tool that can take a round-trip to BPEL and back, providing seamless authoring.

6. A way of letting your process rest in a known condition indefinitely.
a) State
b) Activity
c) Sequence
d) Subprocess

Answer: a
Clarification: “State” can mean many things, but simply, it’s a pause or window in the action.

7. A pause in the action that can only move forward when a known actor or agent in the system moves it forward.
a) State
b) Activity
c) Sequence
d) Subprocess

Answer: b
Clarification: An activity is a pause in the action that can only move forward when a known actor or agent in the system moves it forward.

8. An aggregation of states, activities, and other types of constructs that serializes them.
a) State
b) Activity
c) Sequence
d) Subprocess

Answer: c
Clarification: A sequence is simply an aggregation of states, activities, and other types of constructs that serializes them.

9. A concurrent execution of multiple threads of execution at the same time, originating from a common thread.
a) State
b) Activity
c) Sequence
d) Fork or concurrence or split

Answer: d
Clarification: Some parts of a business process are inherently sequential, and some are readily concurrent.

10. Each department may have its own task list to complete in order to achieve the goals of the overarching process.
a) State
b) Activity
c) Subprocess
d) Fork or concurrence or split

Answer: c
Clarification: These subtasks (basically a separate process unto their own) may be modeled as a subprocess.

11. A decision describes a node that is conditional, based on some logic that you inject.
a) True
b) False

Answer: a
Clarification: You might use this to vary the execution based on some fact that you provide the process as a parameter.

12. To use PostgreSQL, you need to add a the driver library to the classpath.
a) True
b) False

Answer: a
Clarification: You might use this to vary the execution based on some fact that you provide the process as a parameter.

13. To use PostgreSQL, you need to add a the driver library to the classpath.
a) True
b) False

Answer: a
Clarification: If you are using Maven, add the following dependency to your project.

<dependency>
   <groupId>postgresql</groupId>
   <artifactId>postgresql</artifactId>
   <version>8.3-603.jdbc3</version>
</dependency>

14.

<dependency>
        <groupId>org.jbpm.jbpm4</groupId>
        <artifactId>jbpm-jpdl</artifactId>
        <version>4.3</version>
</dependency>

Dependency for JBPM 4.
a) True
b) False

Answer: a
Clarification: If you’re looking to find out more, read the documentation, and get the downloadable binaries for exploration, check out http://jboss.org/jbossjbpm/.

15. JBPM supports databases such as:-
a) Oracle
b) SQL Server
c) MySql
d) All of the mentioned

Answer: d
Clarification: It’s hard to find an exhaustive or conclusive list of supported databases for jBPM, but because it’s built on Hibernate, you can expect it’s going to work on the big-name databases: Oracle, SQL Server, MySQL, PostgreSQL, and so forth.

Java Spring for aptitude tests,

250+ TOP MCQs on Accessing and Integrating Spring with known Frameworks and Answers

Java Spring Multiple Choice Questions & Answers (MCQs) on “Accessing and Integrating Spring with known Frameworks”.

1. Servlet listener which loads application context.
a) Security:intercept-methods
b) global-method-security
c) ContextLoaderListener
d) None of the mentioned
Answer: c
Clarification: A web application can load Spring application context by registering the servlet listener ContextLoaderListener.

2. Method to retrieve Spring Applicationcontext.
a) WebApplicationContextUtils.getRequiredWebApplicationContext()
b) WebApplicationContextUtils.getRequiredWeb()
c) WebApplicationUtils.getRequiredWebApplicationContext()
d) None of the mentioned
Answer: a
Clarification: As Spring applicationcontext is stored in the servlet context, you can retrieve it through the WebApplicationContextUtils.getRequiredWebApplicationContext() method by passing in a servlet context.

3. Class used to have full access to the Spring context’s life cycle machinery and dependency injection.
a) DelegatingFilterProxy
b) WebApplicationContextUtils.getRequiredWeb()
c) WebApplicationUtils.getRequiredWebApplicationContext()
d) None of the mentioned
Answer: a
Clarification: If you want to implement filter-like functionality but want to have full access to the Spring context’s life cycle machinery and dependency injection, use the DelegatingFilterProxy class.

4. In order to leverage Spring application context machinery and configuration.
a) HttpRequestHandlerJNDI
b) HttpRequestHandlerServlet
c) HttpRequestHandler
d) None of the mentioned
Answer: b
Clarification: Suppose we wanted to rewrite the servlet functionality to leverage Spring application context machinery and configuration. The HttpRequestHandlerServlet will handle this for us.

5. Interface implemented by object instantiated by HttpRequestHandlerServlet.
a) HttpRequestHandlerJNDI
b) HttpRequestHandlerServlet
c) HttpRequestHandler
d) None of the mentioned
Answer: c
Clarification: In the servlet example, the HttpRequestHandlerServlet delegated to another object that implemented an interface—HttpRequestHandler—that was considerably simpler than that of a raw servlet.

6. Attribute used to look up and delegate a particular root bean.
a) filter
b) filter-name
c) filtername
d) none of the mentioned
Answer: b
Clarification: the filter-name attribute is used to determine which bean in the root Spring application context to look up and delegate to.

7. ActionSupport class provides a method to access spring application context.
a) getWebApplicationContext()
b) getWebApplication()
c) getApplicationContext()
d) contextEventListener()
Answer: a
Clarification: Spring provides the ActionSupport class, a subclass of the Action base class that has a convenient getWebApplicationContext() method for you to access Spring application context.

8. Struts servlet used to handle web requests.
a) ActionServlet
b) Action
c) ActionSupport
d) ActionStruts
Answer: a
Clarification: In the web deployment descriptor (i.e., web.xml) of a Struts application, you have to register the Struts servlet ActionServlet to handle web requests.

9. Struts plugin used to integrate with spring.
a) ContextLoaderListener
b) ContextLoaderPlugin
c) ContextLoaderListenerPlugin
d) None of the mentioned
Answer: b
Clarification: Another way is to register the Struts plug-in ContextLoaderPlugin in the Struts configuration file.

10. Integration of JSF with Spring Application Context.
a) ContextLoaderListener
b) DelegatingVariableResolver
c) SpringBeanFacesELResolver
d) All of the mentioned
Answer: d
Clarification: Due to the similarity between Spring and JSF bean models, it’s very easy to integrate them by registering the Spring-provided JSF variable resolver DelegatingVariableResolver (for JSF 1.1) or the SpringBeanFacesELResolver (for JSF 1.2 and greater).

11. To handle web requests in JSF.
a) FacesServlet
b) JavaFacesServlet
c) Faces-Servlet
d) None of the mentioned
Answer: a
Clarification: In the web deployment descriptor (i.e., web.xml) of a JSF application, you have to register the JSF servlet FacesServlet to handle web requests.

12. Component of JSF, for user’s input in a form.
a) h:form
b) h:commandButton
c) h:outputText
d) h:inputText
Answer: a
Clarification: h:form component for users to fill form.

13. Tag used to provide result of web requests and is read only.
a) h:form
b) h:commandButton
c) h:outputText
d) h:inputText
Answer: c
Clarification: The distance result is defined using an h:outputText component because its value is read-only.

14. Tag which triggers server side requests.
a) h:form
b) h:commandButton
c) h:outputText
d) h:inputText
Answer: b
Clarification: You define an h:commandButton component whose action will be triggered on the server side when you click it.

15. Tag used to integrate Spring with DWR.
a) dwr:integrate
b) dwr:remote
c) dwr:action
d) none of the mentioned
Answer: b
Clarification: You can simply configure which beans to expose for remote invocation by embedding the tag without involving the DWR configuration file.

250+ TOP MCQs on Custom Layouts,Tags and Templates and Answers

Java Spring Multiple Choice Questions & Answers (MCQs) on “Custom Layouts,Tags and Templates”.

1. A Grails view can contain:-
a) HTML Tags
b) GSP or JSTL Tags
c) Groovy or Java code
d) All of the mentioned
Answer: d
Clarification: A Grails view can contain display elements (e.g., HTML tags), business logic elements (e.g., GSP or JSTL tags) or straightforward Groovy or Java code to achieve its display objectives.

2. A view can require a unique combination of display elements and business logic.
a) True
b) False
Answer: a
Clarification: To simplify the inclusion of such a combination and facilitate its reuse in multiple views a custom tag can be used.

3. To create custom tags.
a) grails create tag
b) grails create-tag-lib tag-lib-name
c) all of the mentioned
d) none of the mentioned
Answer: b
Clarification: To create custom tags, you can use the grails create-tag-lib tag-lib-name command.

4. grails create-tag-lib tag-lib-name command creates a custom tag library under:-
a) /grails-app/tag/
b) /grails-app/
c) /grails-app/tag-lib/
d) none of the mentioned
Answer: c
Clarification: This command creates a skeleton class for a custom tag library under an application’s /grails-app/tag-lib/ directory.

5. In order for this custom tag to function properly in JSP, it’s necessary to add it to the corresponding Tag Library Definition (TLD) grails.tld.
a) True
b) False
Answer: a
Clarification: TLDs are located in an application’s /web-app/WEB-INF/tld/ directory.

6. Custom tags can also rely on input parameters.
a) True
b) False
Answer: a
Clarification: Custom tags can also rely on input parameters passed in as tag attributes to perform a backing class’s logic.

7. By default, Grails assigns custom tags to:-
a) g: namespace
b) f: namespace
c) j: namespace
d) all of the mentioned
Answer: a
Clarification: Finally, a word about the namespace used in Grails custom tags—by default, Grails assigns custom tags to the g: namespace.

8. By default, Grails applies a global layout to display an application’s content.
a) True
b) False
Answer: a
Clarification: This allows views to have a minimal set of display elements (e.g., HTML, CSS, and JavaScript) and inherit their layout behavior from a separate location.

9. Grails doesn’t supports the concept of templates.
a) True
b) False
Answer: b
Clarification: Grails also supports the concept of templates, which serve the same purpose as layouts, except applied at a more granular level. In addition, it’s also possible to use templates for rendering a controller’s output, instead of a view as in most controllers.

10. Where is subdirectory called layouts located, containing the layouts available to an application?
a) /grails-app/view/
b) /grails-app/
c) /grails-app/view/WEB-INF
d) none of the mentioned
Answer: a
Clarification: Inside the /grails-app/view/ directory of an application, you can find a subdirectory called layouts, containing the layouts available to an application.

11. Tag is used to define the contents of a layout’s title section.
a) g:layoutTitle
b) g:layoutHead
c) g:layoutBody
d) g:layoutMeta
Answer: a
Clarification: The g:layoutTitle tag is used to define the contents of a layout’s title section.

12. Tag is used to define the contents of a layout’s head section.
a) g:layoutTitle
b) g:layoutHead
c) g:layoutBody
d) g:layoutMeta
Answer: b
Clarification: Any values declared in the head of a view head inheriting this layout are placed in this location upon rendering.

13. Tag allows any view inheriting this layout automatic access to JavaScript libraries.
a) g:javascript library=”application”
b) g:layoutHead
c) g:layoutBody
d) g:layoutMeta
Answer: a
Clarification: Upon rendering, this element is transformed into the following: script type=”text/javascript” src=”/court/js/application.js” /script.

14. A view’s body content is inside the:-
a) g:javascript library=”application”
b) g:layoutHead
c) g:layoutBody
d) g:layoutMeta
Answer: c
Clarification: Grails automatically sorts out the substitution process by placing a view’s title content inside the g:layoutTitle tag, a view’s body content inside the g:layoutBody / tag, and so on.

15. GORM dynamic finder comparators:-
a) InList
b) LessThan
c) LessThanEquals
d) All of the mentioned
Answer: d
Clarification: GORM comparator Query
InList If value is present in a given list of values
LessThan For lesser object(s) than the given value
LessThanEquals For lesser or equal object(s) than the given value
GreaterThan For greater object(s) than the given value
GreaterThanEquals For greater or equal object(s) than the given value
Like For object(s) like the given value
Ilike For object(s) like the given value in a case insensitive manner
NotEqual For object(s) not equal to the given value
Between For object(s) between to the two given values
IsNotNull For not null object(s); uses no arguments
IsNull For null object(s); uses no arguments