Package net.md_5.bungee
Class Util
- java.lang.Object
- 
- net.md_5.bungee.Util
 
- 
 public class Util extends Object Series of utility classes to perform various operations.
- 
- 
Field SummaryFields Modifier and Type Field Description static intDEFAULT_PORT
 - 
Constructor SummaryConstructors Constructor Description Util()
 - 
Method SummaryAll Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static Stringcsv(Iterable<?> objects)static Stringexception(Throwable t)Constructs a pretty one line version of aThrowable.static Stringexception(Throwable t, boolean includeLineNumbers)Constructs a pretty one line version of aThrowable.static Stringformat(Iterable<?> objects, String separators)Deprecated.useStringjoin methodsstatic SocketAddressgetAddr(String hostline)Method to transform human readable addresses into usable address objects.static UUIDgetUUID(String uuid)Converts a String to a UUIDstatic Stringhex(int i)Formats an integer as a hex value.static Stringunicode(char c)Formats an char as a unicode value.
 
- 
- 
- 
Field Detail- 
DEFAULT_PORTpublic static final int DEFAULT_PORT - See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
getAddrpublic static SocketAddress getAddr(String hostline) Method to transform human readable addresses into usable address objects.- Parameters:
- hostline- in the format of 'host:port'
- Returns:
- the constructed hostname + port.
 
 - 
hexpublic static String hex(int i) Formats an integer as a hex value.- Parameters:
- i- the integer to format
- Returns:
- the hex representation of the integer
 
 - 
unicodepublic static String unicode(char c) Formats an char as a unicode value.- Parameters:
- c- the character to format
- Returns:
- the unicode representation of the character
 
 - 
exceptionpublic static String exception(Throwable t) Constructs a pretty one line version of aThrowable. Useful for debugging.
 - 
exceptionpublic static String exception(Throwable t, boolean includeLineNumbers) Constructs a pretty one line version of aThrowable. Useful for debugging.
 - 
format@Deprecated public static String format(Iterable<?> objects, String separators) Deprecated.useStringjoin methodsReturns a string of objects, each separated by a separator.- Parameters:
- objects- the objects to join
- separators- the separator
- Returns:
- joined string
- See Also:
- String.join(java.lang.CharSequence, java.lang.Iterable)
 
 
- 
 
-