FileDocCategorySizeDatePackage
SurfaceSession.javaAPI DocAndroid 5.1 API1841Thu Mar 12 22:22:10 GMT 2015android.view

SurfaceSession

public final class SurfaceSession extends Object
An instance of this class represents a connection to the surface flinger, from which you can create one or more Surface instances that will be composited to the screen. {@hide}

Fields Summary
private long
mNativeClient
Constructors Summary
public SurfaceSession()
Create a new connection with the surface flinger.

        mNativeClient = nativeCreate();
    
Methods Summary
protected voidfinalize()

        try {
            if (mNativeClient != 0) {
                nativeDestroy(mNativeClient);
            }
        } finally {
            super.finalize();
        }
    
public voidkill()
Forcibly detach native resources associated with this object. Unlike destroy(), after this call any surfaces that were created from the session will no longer work.

        nativeKill(mNativeClient);
    
private static native longnativeCreate()

private static native voidnativeDestroy(long ptr)

private static native voidnativeKill(long ptr)