Search in sources :

Example 6 with PluginData

use of android.webkit.PluginData in project android_frameworks_base by DirtyUnicorns.

the class UrlInterceptRegistry method getPluginData.

/**
     * Given an url, returns the PluginData of the first
     * UrlInterceptHandler interested, or null if none are or if
     * intercepts are disabled.
     *
     * @return A PluginData instance containing surrogate content.
     *
     * @hide
     * @deprecated This class was intended to be used by Gears. Since Gears was
     * deprecated, so is this class.
     */
@Deprecated
public static synchronized PluginData getPluginData(String url, Map<String, String> headers) {
    if (urlInterceptDisabled()) {
        return null;
    }
    Iterator iter = getHandlers().listIterator();
    while (iter.hasNext()) {
        UrlInterceptHandler handler = (UrlInterceptHandler) iter.next();
        PluginData data = handler.getPluginData(url, headers);
        if (data != null) {
            return data;
        }
    }
    return null;
}
Also used : UrlInterceptHandler(android.webkit.UrlInterceptHandler) PluginData(android.webkit.PluginData) Iterator(java.util.Iterator)

Example 7 with PluginData

use of android.webkit.PluginData in project android_frameworks_base by ResurrectionRemix.

the class UrlInterceptRegistry method getPluginData.

/**
     * Given an url, returns the PluginData of the first
     * UrlInterceptHandler interested, or null if none are or if
     * intercepts are disabled.
     *
     * @return A PluginData instance containing surrogate content.
     *
     * @hide
     * @deprecated This class was intended to be used by Gears. Since Gears was
     * deprecated, so is this class.
     */
@Deprecated
public static synchronized PluginData getPluginData(String url, Map<String, String> headers) {
    if (urlInterceptDisabled()) {
        return null;
    }
    Iterator iter = getHandlers().listIterator();
    while (iter.hasNext()) {
        UrlInterceptHandler handler = (UrlInterceptHandler) iter.next();
        PluginData data = handler.getPluginData(url, headers);
        if (data != null) {
            return data;
        }
    }
    return null;
}
Also used : UrlInterceptHandler(android.webkit.UrlInterceptHandler) PluginData(android.webkit.PluginData) Iterator(java.util.Iterator)

Example 8 with PluginData

use of android.webkit.PluginData in project android_frameworks_base by crdroidandroid.

the class UrlInterceptRegistry method getPluginData.

/**
     * Given an url, returns the PluginData of the first
     * UrlInterceptHandler interested, or null if none are or if
     * intercepts are disabled.
     *
     * @return A PluginData instance containing surrogate content.
     *
     * @hide
     * @deprecated This class was intended to be used by Gears. Since Gears was
     * deprecated, so is this class.
     */
@Deprecated
public static synchronized PluginData getPluginData(String url, Map<String, String> headers) {
    if (urlInterceptDisabled()) {
        return null;
    }
    Iterator iter = getHandlers().listIterator();
    while (iter.hasNext()) {
        UrlInterceptHandler handler = (UrlInterceptHandler) iter.next();
        PluginData data = handler.getPluginData(url, headers);
        if (data != null) {
            return data;
        }
    }
    return null;
}
Also used : UrlInterceptHandler(android.webkit.UrlInterceptHandler) PluginData(android.webkit.PluginData) Iterator(java.util.Iterator)

Aggregations

PluginData (android.webkit.PluginData)8 UrlInterceptHandler (android.webkit.UrlInterceptHandler)7 Iterator (java.util.Iterator)7