@groovy.transform.CompileStatic class StringToolsProxy extends Object
| Constructor and description |
|---|
protected StringToolsProxy
(ProviderFactory pf) |
| Type Params | Return Type | Name and description |
|---|---|---|
|
String |
hashUri(URI uri)Creates a SHA-256 has of a URI. |
|
String |
packageNameFromUri(URI uri)Get final package or directory name from a URI |
|
URI |
safeUri(URI uri)Create a URI where the user/password is masked out. |
|
String |
stringize(Object stringy)Converts most things to a string. |
|
java.util.List<String> |
stringize(java.util.Collection<?> stringyThings)Converts a collection of most things to a list of strings. |
|
java.util.List<String> |
stringizeDropNull(java.util.Collection<?> stringyThings)Like stringize, but drops any nulls, or empty instances of Provider and java.util.Optional. |
|
String |
stringizeOrNull(Object stringy)Like stringize, but returns null rather than throwing an exception, when item is null,
an empty {@Link Provider} or an empty java.util.Optional. |
|
void |
updateStringProperty(Property<String> provider, Object stringy)Updates a Property<String>. |
|
URI |
urize(Object uriThingy)Attempts to convert object to a URI. |
Creates a SHA-256 has of a URI.
uri - URI to hashGet final package or directory name from a URI
uri - URI to processCreate a URI where the user/password is masked out.
uri - Original URIConverts most things to a string. Closures are evaluated as well.
stringy - An object that can be converted to a string or a closure that
can be evaluated to something that can be converted to a string.Converts a collection of most things to a list of strings. Closures are evaluated as well.
stringyThings - Iterable list of objects that can be converted to strings.Like stringize, but drops any nulls, or empty instances of Provider and java.util.Optional.
Like stringize, but returns null rather than throwing an exception, when item is null,
an empty {
null Updates a Property<String>.
THis provides a more powerful way than Property.set.
provider - String propertystringy - Objexct that is a string or can be converted to a string.