Package one.microstream.meta
Class XDebug
- java.lang.Object
-
- one.microstream.meta.XDebug
-
public final class XDebug extends Object
This is a helper class merely for debugging purposes. None of its members should be used for productive code.
-
-
Constructor Summary
Constructors Constructor Description XDebug()
-
Method Summary
Modifier and Type Method Description static VarString
assembleTable(VarString vs, XGettingTable<?,?> collection, String start, String mapper, String separator, String end, Integer limit)
static void
copyActualFile(Path sourceRoot, Path subject, Path targetRoot)
static byte[]
copyDirectByteBuffer(ByteBuffer bb)
static byte[]
copyDirectByteBufferRange(ByteBuffer bb, int offset, int length)
static void
copyDirectory(Path sourceRoot, Path subject, Path targetRoot)
static void
copyFile(Path sourceRoot, Path subject, Path targetRoot)
static void
deleteAllFiles(Path directory, boolean output)
static String
formatCommonTime(Date timestamp)
static String
formatNanoTime(long timestamp)
static String
formatString(String s, StackTraceElement e)
static <T> T
internalPrintTime(Supplier<? extends T> logic, String name, int stackTraceCallLevel, int stackTraceDepthStart, int stackTraceDepth)
static void
print(String s)
static void
print(String s, int stackTraceCut)
static void
printArray(Object[] array, String start, String separator, String end, Integer limit)
static void
printCollection(XGettingCollection<?> collection, String start, String separator, String end, Integer limit)
static void
printDirectByteBuffer(ByteBuffer bb)
static void
printInstanceSizeInfo(Class<?> c)
static void
println(String s)
static void
println(String s, int stackTraceCut)
static void
printTable(XGettingTable<?,?> collection, String start, String mapper, String separator, String end, Integer limit)
static void
printTime(Runnable logic)
static void
printTime(Runnable logic, int stackTraceDepth)
static void
printTime(Runnable logic, int stackTraceDepthStart, int stackTraceDepth)
static void
printTime(Runnable logic, String name)
static void
printTime(Runnable logic, String name, int stackTraceDepth)
static void
printTime(Runnable logic, String name, int stackTraceDepthStart, int stackTraceDepth)
static <T> T
printTime(Supplier<? extends T> logic)
static <T> T
printTime(Supplier<? extends T> logic, int stackTraceDepth)
static <T> T
printTime(Supplier<? extends T> logic, int stackTraceDepthStart, int stackTraceDepth)
static <T> T
printTime(Supplier<? extends T> logic, String name)
static <T> T
printTime(Supplier<? extends T> logic, String name, int stackTraceDepth)
static <T> T
printTime(Supplier<? extends T> logic, String name, int stackTraceDepthStart, int stackTraceDepth)
static void
resetDirecory(Path target, Path source, boolean output)
-
-
-
Method Detail
-
formatNanoTime
public static String formatNanoTime(long timestamp)
-
println
public static final void println(String s)
-
print
public static final void print(String s)
-
println
public static final void println(String s, int stackTraceCut)
-
print
public static final void print(String s, int stackTraceCut)
-
formatString
public static String formatString(String s, StackTraceElement e)
-
printCollection
public static final void printCollection(XGettingCollection<?> collection, String start, String separator, String end, Integer limit)
-
assembleTable
public static final VarString assembleTable(VarString vs, XGettingTable<?,?> collection, String start, String mapper, String separator, String end, Integer limit)
-
printTable
public static final void printTable(XGettingTable<?,?> collection, String start, String mapper, String separator, String end, Integer limit)
-
printArray
public static final void printArray(Object[] array, String start, String separator, String end, Integer limit)
-
printTime
public static <T> T printTime(Supplier<? extends T> logic)
-
printTime
public static <T> T printTime(Supplier<? extends T> logic, int stackTraceDepth)
-
printTime
public static <T> T printTime(Supplier<? extends T> logic, int stackTraceDepthStart, int stackTraceDepth)
-
printTime
public static <T> T printTime(Supplier<? extends T> logic, String name, int stackTraceDepth)
-
printTime
public static <T> T printTime(Supplier<? extends T> logic, String name, int stackTraceDepthStart, int stackTraceDepth)
-
internalPrintTime
public static <T> T internalPrintTime(Supplier<? extends T> logic, String name, int stackTraceCallLevel, int stackTraceDepthStart, int stackTraceDepth)
-
printTime
public static void printTime(Runnable logic)
-
printTime
public static void printTime(Runnable logic, int stackTraceDepth)
-
printTime
public static void printTime(Runnable logic, int stackTraceDepthStart, int stackTraceDepth)
-
printTime
public static void printTime(Runnable logic, String name, int stackTraceDepthStart, int stackTraceDepth)
-
resetDirecory
public static void resetDirecory(Path target, Path source, boolean output) throws IOException
- Throws:
IOException
-
deleteAllFiles
public static final void deleteAllFiles(Path directory, boolean output)
-
copyFile
public static void copyFile(Path sourceRoot, Path subject, Path targetRoot) throws IOException
- Throws:
IOException
-
copyDirectory
public static void copyDirectory(Path sourceRoot, Path subject, Path targetRoot) throws IOException
- Throws:
IOException
-
copyActualFile
public static void copyActualFile(Path sourceRoot, Path subject, Path targetRoot) throws IOException
- Throws:
IOException
-
copyDirectByteBufferRange
public static byte[] copyDirectByteBufferRange(ByteBuffer bb, int offset, int length)
-
copyDirectByteBuffer
public static byte[] copyDirectByteBuffer(ByteBuffer bb)
-
printDirectByteBuffer
public static void printDirectByteBuffer(ByteBuffer bb)
-
printInstanceSizeInfo
public static void printInstanceSizeInfo(Class<?> c)
-
-