public class ConstructorStream
extends java.lang.Object
| Constructor and Description |
|---|
ConstructorStream(RStream parent) |
| Modifier and Type | Method and Description |
|---|---|
ConstructorWrapper |
by(java.lang.Class<?>... parameterTypes)
Get the
ConstructorWrapper instance of the constructor with the given parameter types |
ConstructorWrapper |
by(int index)
Get the
ConstructorWrapper instance of the constructor with the given index |
ConstructorStream |
filter(boolean isStatic)
Filter out all static/non-static constructors
|
ConstructorStream |
filter(java.lang.Class<?>... parameterTypes)
Filter the constructors by the given parameter types
|
ConstructorStream |
filter(java.util.function.Predicate<ConstructorWrapper> filter)
Filter the constructors by the given predicate
|
ConstructorStream |
forEach(java.util.function.Consumer<ConstructorWrapper> consumer)
Loop through all
ConstructorWrapper instances |
java.util.Iterator<ConstructorWrapper> |
iterator()
Get an iterator of the
ConstructorWrapper instances |
java.util.stream.Stream<ConstructorWrapper> |
jstream()
Get the java stream of the
ConstructorWrapper instances |
RStream |
parent()
Get the parent
RStream instance |
int |
size()
Get the amount of constructors in this stream
|
public ConstructorStream(RStream parent)
public int size()
public ConstructorWrapper by(java.lang.Class<?>... parameterTypes)
ConstructorWrapper instance of the constructor with the given parameter typesparameterTypes - The parameter types of the constructorConstructorWrapper instancejava.lang.NoSuchMethodException - If the constructor doesn't existpublic ConstructorWrapper by(int index)
ConstructorWrapper instance of the constructor with the given indexindex - The index of the constructorConstructorWrapper instancejava.lang.NoSuchMethodException - If the constructor doesn't existpublic ConstructorStream filter(java.util.function.Predicate<ConstructorWrapper> filter)
filter - The predicateConstructorStreampublic ConstructorStream filter(java.lang.Class<?>... parameterTypes)
parameterTypes - The parameter typesConstructorStreampublic ConstructorStream filter(boolean isStatic)
isStatic - Whether the constructor should be static or notConstructorStreampublic java.util.Iterator<ConstructorWrapper> iterator()
ConstructorWrapper instancespublic java.util.stream.Stream<ConstructorWrapper> jstream()
ConstructorWrapper instancespublic ConstructorStream forEach(java.util.function.Consumer<ConstructorWrapper> consumer)
ConstructorWrapper instancesconsumer - The consumerConstructorStream