Merge changes from topic 'api-review' into oc-dev

am: fd89a95f35

Change-Id: I297fcfecc54346ee885916eb2e671497c522001f
This commit is contained in:
Chong Zhang
2017-04-13 06:34:25 +00:00
committed by android-build-merger
4 changed files with 7 additions and 37 deletions

View File

@@ -21809,8 +21809,7 @@ package android.media {
method public void close();
method public static android.media.MediaCas.PluginDescriptor[] enumeratePlugins();
method public static boolean isSystemIdSupported(int);
method public android.media.MediaCas.Session openSession(int) throws android.media.MediaCasException;
method public android.media.MediaCas.Session openSession(int, int) throws android.media.MediaCasException;
method public android.media.MediaCas.Session openSession() throws android.media.MediaCasException;
method public void processEmm(byte[], int, int) throws android.media.MediaCasException;
method public void processEmm(byte[]) throws android.media.MediaCasException;
method public void provision(java.lang.String) throws android.media.MediaCasException;

View File

@@ -23638,8 +23638,7 @@ package android.media {
method public void close();
method public static android.media.MediaCas.PluginDescriptor[] enumeratePlugins();
method public static boolean isSystemIdSupported(int);
method public android.media.MediaCas.Session openSession(int) throws android.media.MediaCasException;
method public android.media.MediaCas.Session openSession(int, int) throws android.media.MediaCasException;
method public android.media.MediaCas.Session openSession() throws android.media.MediaCasException;
method public void processEmm(byte[], int, int) throws android.media.MediaCasException;
method public void processEmm(byte[]) throws android.media.MediaCasException;
method public void provision(java.lang.String) throws android.media.MediaCasException;

View File

@@ -21924,8 +21924,7 @@ package android.media {
method public void close();
method public static android.media.MediaCas.PluginDescriptor[] enumeratePlugins();
method public static boolean isSystemIdSupported(int);
method public android.media.MediaCas.Session openSession(int) throws android.media.MediaCasException;
method public android.media.MediaCas.Session openSession(int, int) throws android.media.MediaCasException;
method public android.media.MediaCas.Session openSession() throws android.media.MediaCasException;
method public void processEmm(byte[], int, int) throws android.media.MediaCasException;
method public void processEmm(byte[]) throws android.media.MediaCasException;
method public void provision(java.lang.String) throws android.media.MediaCasException;

View File

@@ -506,9 +506,8 @@ public final class MediaCas implements AutoCloseable {
}
/**
* Open a session for the specified program.
*
* @param programNumber program_number of the program (as in ISO/IEC13818-1).
* Open a session to descramble one or more streams scrambled by the
* conditional access system.
*
* @return session the newly opened session.
*
@@ -516,37 +515,11 @@ public final class MediaCas implements AutoCloseable {
* @throws MediaCasException for CAS-specific errors.
* @throws MediaCasStateException for CAS-specific state exceptions.
*/
public Session openSession(int programNumber) throws MediaCasException {
public Session openSession() throws MediaCasException {
validateInternalStates();
try {
return createFromSessionId(mICas.openSession(programNumber));
} catch (ServiceSpecificException e) {
MediaCasException.throwExceptions(e);
} catch (RemoteException e) {
cleanupAndRethrowIllegalState();
}
return null;
}
/**
* Open a session for the specified stream.
*
* @param programNumber program_number of the stream (as in ISO/IEC13818-1).
* @param elementaryPID elementary_PID of the stream (as in ISO/IEC13818-1).
*
* @return session the newly opened session.
*
* @throws IllegalStateException if the MediaCas instance is not valid.
* @throws MediaCasException for CAS-specific errors.
* @throws MediaCasStateException for CAS-specific state exceptions.
*/
public Session openSession(int programNumber, int elementaryPID)
throws MediaCasException {
validateInternalStates();
try {
return createFromSessionId(mICas.openSessionForStream(programNumber, elementaryPID));
return createFromSessionId(mICas.openSession());
} catch (ServiceSpecificException e) {
MediaCasException.throwExceptions(e);
} catch (RemoteException e) {