|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object play.test.Fixtures
public class Fixtures
Field Summary | |
---|---|
static java.util.Map<java.lang.String,java.lang.Object> |
idCache
|
Constructor Summary | |
---|---|
Fixtures()
|
Method Summary | ||
---|---|---|
static void |
delete(java.lang.Class<? extends Model>... types)
Delete all Model instances for the given types using the underlying persistence mechanisms |
|
static void |
delete(java.util.List<java.lang.Class<? extends Model>> classes)
Delete all Model instances for the given types using the underlying persistence mechanisms |
|
static void |
deleteAll()
Deprecated. use deleteDatabase() instead |
|
static void |
deleteAllModels()
Delete all Model instances for the all available types using the underlying persistence mechanisms |
|
static void |
deleteDatabase()
Flush the entire JDBC database |
|
static void |
deleteDirectory(java.lang.String path)
Delete a directory recursively |
|
static void |
executeSQL(java.io.File sqlScript)
|
|
static void |
executeSQL(java.lang.String sqlScript)
|
|
static void |
load(java.util.List<java.lang.String> names)
Deprecated. use loadModels(String...) instead |
|
static void |
load(java.lang.String... names)
Deprecated. use loadModels(String...) instead |
|
static void |
load(java.lang.String name)
Deprecated. use loadModels(String...) instead |
|
static void |
loadModels(java.util.List<java.lang.String> names)
|
|
static void |
loadModels(java.lang.String... names)
|
|
static void |
loadModels(java.lang.String name)
Load Model instances from a YAML file and persist them using the underlying persistence mechanism. |
|
static java.lang.Object |
loadYaml(java.lang.String name)
Load and parse a plain YAML file and returns the corresponding Java objects. |
|
static
|
loadYaml(java.lang.String name,
java.lang.Class<T> clazz)
Load and parse a plain YAML file and returns the corresponding Java Map. |
|
static
|
loadYaml(java.lang.String name,
org.yaml.snakeyaml.Yaml yaml)
|
|
static java.util.List<?> |
loadYamlAsList(java.lang.String name)
Load and parse a plain YAML file and returns the corresponding Java List. |
|
static java.util.Map<?,?> |
loadYamlAsMap(java.lang.String name)
Load and parse a plain YAML file and returns the corresponding Java Map. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static java.util.Map<java.lang.String,java.lang.Object> idCache
Constructor Detail |
---|
public Fixtures()
Method Detail |
---|
public static void executeSQL(java.lang.String sqlScript)
public static void executeSQL(java.io.File sqlScript)
public static void delete(java.lang.Class<? extends Model>... types)
types
- Types to deletepublic static void delete(java.util.List<java.lang.Class<? extends Model>> classes)
types
- Types to deletepublic static void deleteAllModels()
@Deprecated public static void deleteAll()
deleteDatabase()
instead
public static void deleteDatabase()
@Deprecated public static void load(java.lang.String name)
loadModels(String...)
instead
name
- public static void loadModels(java.lang.String name)
name
- Name of a YAML file somewhere in the classpath (or conf/)@Deprecated public static void load(java.lang.String... names)
loadModels(String...)
instead
public static void loadModels(java.lang.String... names)
loadModels(String name)
public static void load(java.util.List<java.lang.String> names)
loadModels(String...)
instead
public static void loadModels(java.util.List<java.lang.String> names)
loadModels(String name)
public static java.lang.Object loadYaml(java.lang.String name)
name
- Name of a YAML file somewhere in the classpath (or conf/)me
public static java.util.List<?> loadYamlAsList(java.lang.String name)
name
- Name of a YAML file somewhere in the classpath (or conf/)me
public static java.util.Map<?,?> loadYamlAsMap(java.lang.String name)
name
- Name of a YAML file somewhere in the classpath (or conf/)me
public static <T> T loadYaml(java.lang.String name, java.lang.Class<T> clazz)
name
- Name of a YAML file somewhere in the classpath (or conf/)meclazz
- the expected class
public static <T> T loadYaml(java.lang.String name, org.yaml.snakeyaml.Yaml yaml)
public static void deleteDirectory(java.lang.String path)
path
- relative path of the directory to delete
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |