Added in [API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

# PluginStub

*** ** * ** ***

` public interface PluginStub `   
` `

|---|
| android.webkit.PluginStub |

<br />

*** ** * ** ***

This interface is used to implement plugins in a WebView. A plugin package may extend this class and implement the abstract functions to create embedded or fullscreeen views displayed in a WebView. The PluginStub implementation will be provided the same NPP instance that is created through the native interface.

## Summary

| ### Public methods ||
|---|---|
| ` abstract https://developer.android.com/reference/android/view/View` | ` https://developer.android.com/reference/android/webkit/PluginStub#getEmbeddedView(int,%20android.content.Context)(int NPP, https://developer.android.com/reference/android/content/Context context) ` Return a custom embedded view to draw the plugin. |
| ` abstract https://developer.android.com/reference/android/view/View` | ` https://developer.android.com/reference/android/webkit/PluginStub#getFullScreenView(int,%20android.content.Context)(int NPP, https://developer.android.com/reference/android/content/Context context) ` Return a custom full-screen view to be displayed when the user requests a plugin display as full-screen. |

## Public methods

### getEmbeddedView

Added in [API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public abstract View getEmbeddedView (int NPP, 
                Context context)
```

Return a custom embedded view to draw the plugin.

<br />

| Parameters ||
|---|---|
| `NPP` | `int`: The native NPP instance. <br /> |
| `context` | `Context`: The current application's Context. <br /> |

| Returns ||
|---|---|
| `https://developer.android.com/reference/android/view/View` | A custom View that will be managed by WebView. <br /> |

### getFullScreenView

Added in [API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public abstract View getFullScreenView (int NPP, 
                Context context)
```

Return a custom full-screen view to be displayed when the user requests a plugin display as full-screen. Note that the application may choose not to display this View as completely full-screen.

<br />

| Parameters ||
|---|---|
| `NPP` | `int`: The native NPP instance. <br /> |
| `context` | `Context`: The current application's Context. <br /> |

| Returns ||
|---|---|
| `https://developer.android.com/reference/android/view/View` | A custom View that will be managed by the application. <br /> |