Package org.apache.felix.gogo.command
Class Util
- java.lang.Object
-
- org.apache.felix.gogo.command.Util
-
public class Util extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description Util()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static boolean
compareSubstring(java.util.List<java.lang.String> pieces, java.lang.String s)
static void
copy(java.io.InputStream is, java.io.File dir, java.lang.String destName, java.lang.String destDir, byte[] buffer)
static void
downloadSource(java.io.PrintStream out, java.io.PrintStream err, java.net.URL srcURL, java.io.File localDir, boolean extract)
static java.lang.String
getBundleName(org.osgi.framework.Bundle bundle)
static <T> T
getService(org.osgi.framework.BundleContext bc, java.lang.Class<T> clazz, java.util.List<org.osgi.framework.ServiceReference> refs)
static java.lang.String
getUnderlineString(int len)
static java.lang.String
getValueString(java.lang.Object obj)
static java.io.InputStream
openURL(java.net.URL url)
static java.io.InputStream
openURL(java.net.URLConnection conn)
static java.util.List<java.lang.String>
parseSubstring(java.lang.String value)
static void
setProxyAuth(java.net.URLConnection conn)
static void
ungetServices(org.osgi.framework.BundleContext bc, java.util.List<org.osgi.framework.ServiceReference> refs)
static void
unjar(java.util.jar.JarInputStream jis, java.io.File dir)
static java.lang.String
unparseSubstring(java.util.List<java.lang.String> pieces)
-
-
-
Method Detail
-
getBundleName
public static java.lang.String getBundleName(org.osgi.framework.Bundle bundle)
-
getUnderlineString
public static java.lang.String getUnderlineString(int len)
-
getValueString
public static java.lang.String getValueString(java.lang.Object obj)
-
getService
public static <T> T getService(org.osgi.framework.BundleContext bc, java.lang.Class<T> clazz, java.util.List<org.osgi.framework.ServiceReference> refs)
-
ungetServices
public static void ungetServices(org.osgi.framework.BundleContext bc, java.util.List<org.osgi.framework.ServiceReference> refs)
-
downloadSource
public static void downloadSource(java.io.PrintStream out, java.io.PrintStream err, java.net.URL srcURL, java.io.File localDir, boolean extract)
-
unjar
public static void unjar(java.util.jar.JarInputStream jis, java.io.File dir) throws java.io.IOException
- Throws:
java.io.IOException
-
copy
public static void copy(java.io.InputStream is, java.io.File dir, java.lang.String destName, java.lang.String destDir, byte[] buffer) throws java.io.IOException
- Throws:
java.io.IOException
-
setProxyAuth
public static void setProxyAuth(java.net.URLConnection conn) throws java.io.IOException
- Throws:
java.io.IOException
-
openURL
public static java.io.InputStream openURL(java.net.URL url) throws java.io.IOException
- Throws:
java.io.IOException
-
openURL
public static java.io.InputStream openURL(java.net.URLConnection conn) throws java.io.IOException
- Throws:
java.io.IOException
-
parseSubstring
public static java.util.List<java.lang.String> parseSubstring(java.lang.String value)
-
unparseSubstring
public static java.lang.String unparseSubstring(java.util.List<java.lang.String> pieces)
-
compareSubstring
public static boolean compareSubstring(java.util.List<java.lang.String> pieces, java.lang.String s)
-
-