| Package | Description |
|---|---|
| org.osgl | |
| org.osgl.util | |
| org.osgl.util.algo |
| Modifier and Type | Field and Description |
|---|---|
static Osgl.Break |
Osgl.BREAK
A predefined Break instance without payload
|
| Modifier and Type | Method and Description |
|---|---|
protected Osgl.Break |
Osgl.FuncBase.breakOut(Object payload)
Return a
Osgl.Break with payload. |
static <T> Osgl.Break |
Osgl.breakOut(T e)
A utility method to throw out a Break with payload
|
| Modifier and Type | Method and Description |
|---|---|
R |
Osgl.Func0.apply()
user application to implement main logic of applying the function
|
T |
Osgl.Factory.apply() |
T |
Osgl.Var.apply() |
R |
Osgl.Func2.apply(P1 p1,
P2 p2)
Apply the two params to the function
|
Void |
Osgl.V2.apply(P1 p1,
P2 p2) |
R |
Osgl.Func3.apply(P1 p1,
P2 p2,
P3 p3)
Run the function with parameters specified.
|
Void |
Osgl.V3.apply(P1 p1,
P2 p2,
P3 p3) |
R |
Osgl.Func4.apply(P1 p1,
P2 p2,
P3 p3,
P4 p4)
Run the function with parameters specified.
|
Void |
Osgl.V4.apply(P1 p1,
P2 p2,
P3 p3,
P4 p4) |
R |
Osgl.Func5.apply(P1 p1,
P2 p2,
P3 p3,
P4 p4,
P5 p5)
Run the function with parameters specified.
|
Void |
Osgl.V5.apply(P1 p1,
P2 p2,
P3 p3,
P4 p4,
P5 p5) |
U |
Osgl.Function.apply(T t)
Apply this function to <T> type parameter.
|
T |
Osgl.Processor.apply(T t) |
Integer |
Osgl.Comparator.apply(T p1,
T p2) |
protected void |
Osgl.Var.forEachLeft(Osgl.Func2<Integer,? super T,?> indexedVisitor) |
protected void |
Osgl.Var.forEachLeft(Osgl.Function<? super T,?> visitor) |
protected void |
Osgl.Var.forEachRight(Osgl.Func2<Integer,? super T,?> indexedVisitor) |
protected void |
Osgl.Var.forEachRight(Osgl.Function<? super T,?> visitor) |
abstract void |
Osgl.Processor.process(T t)
Subclass must override thie method to process the parameter
|
abstract void |
Osgl.Visitor.visit(T t)
User application to implement visit logic in this method
|
| Modifier and Type | Method and Description |
|---|---|
Byte |
N.ByteRangeStep.apply(Byte from,
Integer steps) |
Object |
SimpleObjectFactory.apply(Class<?> aClass) |
Integer |
N.IntRangeStep.apply(Integer from,
Integer steps) |
Long |
N.LongRangeStep.apply(Long from,
Integer steps) |
Short |
N.ShortRangeStep.apply(Short from,
Integer steps) |
T |
StringValueResolver.apply(String s) |
Object |
SimpleStringValueResolver.apply(String s,
Class<?> aClass) |
T |
N.RangeStep.apply(T t,
Integer steps) |
static <T> void |
C.forEach(Iterable<? extends T> iterable,
Osgl.Function<? super T,?> visitor)
Run visitor function on each element supplied by the iterable.
|
static <K,V> void |
C.forEach(Map<K,V> map,
Osgl.Func2<? super K,? super V,?> indexedVisitor)
Run indexedVisitor function on all key/value pair in a given map.
|
SetBase<T> |
SetBase.forEach(Osgl.Function<? super T,?> visitor)
Sub class could override this method to implement iterating in parallel.
|
protected void |
ListBase.forEachLeft(Osgl.Func2<Integer,? super T,?> indexedVisitor) |
protected void |
ListBase.forEachLeft(Osgl.Function<? super T,?> visitor) |
protected void |
ListBase.forEachRight(Osgl.Func2<Integer,? super T,?> indexedVisitor) |
protected void |
ListBase.forEachRight(Osgl.Function<? super T,?> visitor) |
| Modifier and Type | Method and Description |
|---|---|
T[] |
ArrayReverse.apply(T[] ts,
Integer from,
Integer to) |
T[] |
ArrayReverseInplace.apply(T[] ts,
Integer from,
Integer to) |
T[] |
ArraySortInplaceBase.apply(T[] ts,
Integer from,
Integer to,
Comparator<T> comp) |
T[] |
ArraySortBase.apply(T[] ts,
Integer from,
Integer to,
Comparator<T> comp) |
Copyright © 2017. All Rights Reserved.