Class SystemServiceV1
- java.lang.Object
-
- aero.panasonic.inflight.services.servicecontrol.SystemServiceV1
-
public class SystemServiceV1 extends java.lang.ObjectPackage Starting Point - The SystemServiceV1 provides a way to get information about a particular service and whether the service is enabled or disabled temporarily and/or the service is blocked for usage for the flight.
A good example would be blocking a particular feature on an interactive and/or portal. The GUI can query for the service state, and decide on feature availability.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceSystemServiceV1.AvailableServicesListChangedListenerThe AvailableServicesListChangedListener will be invoked when available list of services changes.static interfaceSystemServiceV1.AvailableServicesListReadyListenerinterface for internal use.static classSystemServiceV1.ServiceStatestatic interfaceSystemServiceV1.ServiceStateChangedListenerThe ServiceStateChangedListener will be invoked when specific service gets enabled/disabled or blocked.static classSystemServiceV1.SystemServiceInfoThis class provides api to get information about a particular service and whether the service is enabled or disabled temporarily and/or the service is blocked for usage for the flight.static classSystemServiceV1.SystemServiceInfoError
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringSDK_VERSION
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<SystemServiceV1.SystemServiceInfo>getAvailableServicesList()This api can be used to get the list of all available services on headend.SystemServiceV1.AvailableServicesListChangedListenercan be used to capture change events to the available services.java.util.List<SystemServiceV1.SystemServiceInfo>getSeatServicesList()This api can be used to get a subset of available services list, returning services that are specific to seat.SystemServiceV1.ServiceStategetServiceState(java.lang.String serviceCode)This api can be used to get the State of the given service.static voidinitService(Context context, IInFlightCallback inFlightCallback, InFlight inFlight)Initialize a CatalogDataV1 object and return the object with the IInFlightCallback.voidsetAvailableServicesListChangedListener(SystemServiceV1.AvailableServicesListChangedListener availablesServicesListener)This api is used to set theSystemServiceV1.AvailableServicesListChangedListener.voidsetServiceStateChangedListener(SystemServiceV1.ServiceStateChangedListener serviceStateChangedListener)This api is used to set theSystemServiceV1.ServiceStateChangedListener.
-
-
-
Method Detail
-
initService
public static void initService(Context context, IInFlightCallback inFlightCallback, InFlight inFlight)Initialize a CatalogDataV1 object and return the object with the IInFlightCallback.- Parameters:
context- : provide a Context to initialize the object.inFlightCallback- : IInFlightCallback will be used to return the instance or providing the error message.inFlight- : provide an InFlight instance to initialize
-
getAvailableServicesList
public java.util.List<SystemServiceV1.SystemServiceInfo> getAvailableServicesList()
This api can be used to get the list of all available services on headend.SystemServiceV1.AvailableServicesListChangedListenercan be used to capture change events to the available services.- Example:
SystemServiceV1.initService(activity, inflightCallbackListener, new InFlight()); public void onInitServiceComplete(Object service,String serviceName) { if (service instanceof SystemServiceV1) { mSystemServiceInfoV1 = (SystemServiceInfoV1) service; List< SystemServiceInfo > availableServices = mSystemServiceInfoV1.getAvailableServicesList(); } }
-
getSeatServicesList
public java.util.List<SystemServiceV1.SystemServiceInfo> getSeatServicesList()
This api can be used to get a subset of available services list, returning services that are specific to seat.- Example:
SystemServiceV1.initService(activity, inflightCallbackListener, new InFlight()); public void onInitServiceComplete(Object service,String serviceName) { if (service instanceof SystemServiceV1) { mSystemServiceInfoV1 = (SystemServiceInfoV1) service; List< SystemServiceInfo > seatServices = mSystemServiceInfoV1.getSeatServicesList(); } }
-
setAvailableServicesListChangedListener
public void setAvailableServicesListChangedListener(SystemServiceV1.AvailableServicesListChangedListener availablesServicesListener)
This api is used to set theSystemServiceV1.AvailableServicesListChangedListener. This listener will be invoked whenever available services list has been changed.- Parameters:
availablesServicesListener-
-
setServiceStateChangedListener
public void setServiceStateChangedListener(SystemServiceV1.ServiceStateChangedListener serviceStateChangedListener)
This api is used to set theSystemServiceV1.ServiceStateChangedListener. This listener will be invoked whenever specific service list has changed or any of the service state had changed.- Parameters:
serviceStateChangedListener-
-
getServiceState
public SystemServiceV1.ServiceState getServiceState(java.lang.String serviceCode) throws SystemServiceInvalidServiceCodeException
This api can be used to get the State of the given service.- Parameters:
serviceCode- : service code- Returns:
- ServiceState: State of the service
- Throws:
SystemServiceInvalidServiceCodeException- See Also:
SystemServiceInvalidServiceCodeException
-
-