Package org.robolectric.shadows
Class ModuleInfoBuilder
- java.lang.Object
-
- org.robolectric.shadows.ModuleInfoBuilder
-
public final class ModuleInfoBuilder extends Object
Builder forModuleInfoas ModuleInfo has hidden constructors, this builder class has been added as a way to make custom ModuleInfo objects when needed.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ModuleInfobuild()Returns aModuleInfowith the data that was given.static ModuleInfoBuildernewBuilder()Start building a new ModuleInfoModuleInfoBuildersetHidden(boolean hidden)Sets whether or not the module is hiddenModuleInfoBuildersetName(CharSequence name)Sets the public name of the moduleModuleInfoBuildersetPackageName(String packageName)Sets the package name of the module
-
-
-
Method Detail
-
newBuilder
public static ModuleInfoBuilder newBuilder()
Start building a new ModuleInfo- Returns:
- a new instance of
ModuleInfoBuilder.
-
setName
public ModuleInfoBuilder setName(CharSequence name)
Sets the public name of the module
-
setPackageName
public ModuleInfoBuilder setPackageName(String packageName)
Sets the package name of the module
-
setHidden
public ModuleInfoBuilder setHidden(boolean hidden)
Sets whether or not the module is hidden
-
build
public ModuleInfo build()
Returns aModuleInfowith the data that was given. Both name and packageName are mandatory to build, but hidden is optional, if no value was given will default to false
-
-