////
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements.  See the NOTICE file
distributed with this work for additional information
regarding copyright ownership.  The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License.  You may obtain a copy of the License at

https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied.  See the License for the
specific language governing permissions and limitations
under the License.
////


== getAll



=== Purpose


Retrieves a `List` of instances of the domain class for the specified ids, ordered by the original ids list. If some of the provided ids are `null` or there are no instances with these ids, the resulting `List` will have `null` values in those positions.


=== Examples


[source,groovy]
----
// get a list which contains Book instances with ids 2, 1, 3 respectively
def bookList = Book.getAll(2, 1, 3)

// can take a list of ids as only argument, very
// useful when the ids list is calculated in code
def bookList = Book.getAll([1, 2, 3])

// when called without arguments returns list of all objects
def bookList = Book.getAll()
----


=== Description


Parameters:

* `varargs`* - A variable argument list of ids
* `ids`* - A list of ids
