1 /* 2 * Copyright (C) 2018 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package com.android.internal.telephony; 18 19 import android.app.PendingIntent; 20 import android.net.Uri; 21 import android.os.Bundle; 22 23 import java.util.List; 24 25 /** 26 * Base class for ISms that facilitates forward compatibility with new features. 27 */ 28 public class ISmsImplBase extends ISms.Stub { 29 30 @Override getAllMessagesFromIccEfForSubscriber(int subId, String callingPkg)31 public List<SmsRawData> getAllMessagesFromIccEfForSubscriber(int subId, String callingPkg) { 32 throw new UnsupportedOperationException(); 33 } 34 35 @Override updateMessageOnIccEfForSubscriber(int subId, String callingPkg, int messageIndex, int newStatus, byte[] pdu)36 public boolean updateMessageOnIccEfForSubscriber(int subId, String callingPkg, int messageIndex, 37 int newStatus, byte[] pdu) { 38 throw new UnsupportedOperationException(); 39 } 40 41 @Override copyMessageToIccEfForSubscriber(int subId, String callingPkg, int status, byte[] pdu, byte[] smsc)42 public boolean copyMessageToIccEfForSubscriber(int subId, String callingPkg, int status, 43 byte[] pdu, byte[] smsc) { 44 throw new UnsupportedOperationException(); 45 } 46 47 @Override sendDataForSubscriber(int subId, String callingPkg, String callingAttributionTag, String destAddr, String scAddr, int destPort, byte[] data, PendingIntent sentIntent, PendingIntent deliveryIntent)48 public void sendDataForSubscriber(int subId, String callingPkg, String callingAttributionTag, 49 String destAddr, String scAddr, int destPort, byte[] data, PendingIntent sentIntent, 50 PendingIntent deliveryIntent) { 51 throw new UnsupportedOperationException(); 52 } 53 54 @Override sendTextForSubscriber(int subId, String callingPkg, String callingAttributionTag, String destAddr, String scAddr, String text, PendingIntent sentIntent, PendingIntent deliveryIntent, boolean persistMessageForNonDefaultSmsApp)55 public void sendTextForSubscriber(int subId, String callingPkg, String callingAttributionTag, 56 String destAddr, String scAddr, String text, PendingIntent sentIntent, 57 PendingIntent deliveryIntent, boolean persistMessageForNonDefaultSmsApp) { 58 throw new UnsupportedOperationException(); 59 } 60 61 @Override sendTextForSubscriberWithOptions(int subId, String callingPkg, String callingAttributionTag, String destAddr, String scAddr, String text, PendingIntent sentIntent, PendingIntent deliveryIntent, boolean persistMessageForNonDefaultSmsApp, int priority, boolean expectMore, int validityPeriod)62 public void sendTextForSubscriberWithOptions(int subId, String callingPkg, 63 String callingAttributionTag, String destAddr, String scAddr, String text, 64 PendingIntent sentIntent, PendingIntent deliveryIntent, 65 boolean persistMessageForNonDefaultSmsApp, int priority, boolean expectMore, 66 int validityPeriod) { 67 throw new UnsupportedOperationException(); 68 } 69 70 @Override injectSmsPduForSubscriber( int subId, byte[] pdu, String format, PendingIntent receivedIntent)71 public void injectSmsPduForSubscriber( 72 int subId, byte[] pdu, String format, PendingIntent receivedIntent) { 73 throw new UnsupportedOperationException(); 74 } 75 76 @Override sendMultipartTextForSubscriber(int subId, String callingPkg, String callingAttributionTag, String destinationAddress, String scAddress, List<String> parts, List<PendingIntent> sentIntents, List<PendingIntent> deliveryIntents, boolean persistMessageForNonDefaultSmsApp)77 public void sendMultipartTextForSubscriber(int subId, String callingPkg, 78 String callingAttributionTag, String destinationAddress, String scAddress, 79 List<String> parts, List<PendingIntent> sentIntents, 80 List<PendingIntent> deliveryIntents, boolean persistMessageForNonDefaultSmsApp) { 81 throw new UnsupportedOperationException(); 82 } 83 84 @Override sendMultipartTextForSubscriberWithOptions(int subId, String callingPkg, String callingAttributionTag, String destinationAddress, String scAddress, List<String> parts, List<PendingIntent> sentIntents, List<PendingIntent> deliveryIntents, boolean persistMessageForNonDefaultSmsApp, int priority, boolean expectMore, int validityPeriod)85 public void sendMultipartTextForSubscriberWithOptions(int subId, String callingPkg, 86 String callingAttributionTag, String destinationAddress, String scAddress, 87 List<String> parts, List<PendingIntent> sentIntents, 88 List<PendingIntent> deliveryIntents, boolean persistMessageForNonDefaultSmsApp, 89 int priority, boolean expectMore, int validityPeriod) { 90 throw new UnsupportedOperationException(); 91 } 92 93 @Override enableCellBroadcastForSubscriber(int subId, int messageIdentifier, int ranType)94 public boolean enableCellBroadcastForSubscriber(int subId, int messageIdentifier, int ranType) { 95 throw new UnsupportedOperationException(); 96 } 97 98 @Override disableCellBroadcastForSubscriber(int subId, int messageIdentifier, int ranType)99 public boolean disableCellBroadcastForSubscriber(int subId, int messageIdentifier, 100 int ranType) { 101 throw new UnsupportedOperationException(); 102 } 103 104 @Override enableCellBroadcastRangeForSubscriber(int subId, int startMessageId, int endMessageId, int ranType)105 public boolean enableCellBroadcastRangeForSubscriber(int subId, int startMessageId, 106 int endMessageId, int ranType) { 107 throw new UnsupportedOperationException(); 108 } 109 110 @Override disableCellBroadcastRangeForSubscriber(int subId, int startMessageId, int endMessageId, int ranType)111 public boolean disableCellBroadcastRangeForSubscriber(int subId, int startMessageId, 112 int endMessageId, int ranType) { 113 throw new UnsupportedOperationException(); 114 } 115 116 @Override getPremiumSmsPermission(String packageName)117 public int getPremiumSmsPermission(String packageName) { 118 throw new UnsupportedOperationException(); 119 } 120 121 @Override getPremiumSmsPermissionForSubscriber(int subId, String packageName)122 public int getPremiumSmsPermissionForSubscriber(int subId, String packageName) { 123 throw new UnsupportedOperationException(); 124 } 125 126 @Override setPremiumSmsPermission(String packageName, int permission)127 public void setPremiumSmsPermission(String packageName, int permission) { 128 throw new UnsupportedOperationException(); 129 } 130 131 @Override setPremiumSmsPermissionForSubscriber(int subId, String packageName, int permission)132 public void setPremiumSmsPermissionForSubscriber(int subId, String packageName, 133 int permission) { 134 throw new UnsupportedOperationException(); 135 } 136 137 @Override isImsSmsSupportedForSubscriber(int subId)138 public boolean isImsSmsSupportedForSubscriber(int subId) { 139 throw new UnsupportedOperationException(); 140 } 141 142 @Override isSmsSimPickActivityNeeded(int subId)143 public boolean isSmsSimPickActivityNeeded(int subId) { 144 throw new UnsupportedOperationException(); 145 } 146 147 @Override getPreferredSmsSubscription()148 public int getPreferredSmsSubscription() { 149 throw new UnsupportedOperationException(); 150 } 151 152 @Override getImsSmsFormatForSubscriber(int subId)153 public String getImsSmsFormatForSubscriber(int subId) { 154 throw new UnsupportedOperationException(); 155 } 156 157 @Override isSMSPromptEnabled()158 public boolean isSMSPromptEnabled() { 159 throw new UnsupportedOperationException(); 160 } 161 162 @Override sendStoredText(int subId, String callingPkg, String callingAttributionTag, Uri messageUri, String scAddress, PendingIntent sentIntent, PendingIntent deliveryIntent)163 public void sendStoredText(int subId, String callingPkg, String callingAttributionTag, 164 Uri messageUri, String scAddress, PendingIntent sentIntent, 165 PendingIntent deliveryIntent) { 166 throw new UnsupportedOperationException(); 167 } 168 169 @Override sendStoredMultipartText(int subId, String callingPkg, String callingAttributionTag, Uri messageUri, String scAddress, List<PendingIntent> sentIntents, List<PendingIntent> deliveryIntents)170 public void sendStoredMultipartText(int subId, String callingPkg, String callingAttributionTag, 171 Uri messageUri, String scAddress, List<PendingIntent> sentIntents, 172 List<PendingIntent> deliveryIntents) { 173 throw new UnsupportedOperationException(); 174 } 175 176 @Override getCarrierConfigValuesForSubscriber(int subId)177 public Bundle getCarrierConfigValuesForSubscriber(int subId) { 178 throw new UnsupportedOperationException(); 179 } 180 181 @Override createAppSpecificSmsToken(int subId, String callingPkg, PendingIntent intent)182 public String createAppSpecificSmsToken(int subId, String callingPkg, PendingIntent intent) { 183 throw new UnsupportedOperationException(); 184 } 185 186 @Override createAppSpecificSmsTokenWithPackageInfo( int subId, String callingPkg, String prefixes, PendingIntent intent)187 public String createAppSpecificSmsTokenWithPackageInfo( 188 int subId, String callingPkg, String prefixes, PendingIntent intent) { 189 throw new UnsupportedOperationException(); 190 } 191 192 @Override checkSmsShortCodeDestination(int subid, String callingPackage, String callingFeatureId, String destAddress, String countryIso)193 public int checkSmsShortCodeDestination(int subid, String callingPackage, 194 String callingFeatureId, String destAddress, String countryIso) { 195 throw new UnsupportedOperationException(); 196 } 197 198 @Override getSmscAddressFromIccEfForSubscriber(int subId, String callingPackage)199 public String getSmscAddressFromIccEfForSubscriber(int subId, String callingPackage) { 200 throw new UnsupportedOperationException(); 201 } 202 203 @Override setSmscAddressOnIccEfForSubscriber( String smsc, int subId, String callingPackage)204 public boolean setSmscAddressOnIccEfForSubscriber( 205 String smsc, int subId, String callingPackage) { 206 throw new UnsupportedOperationException(); 207 } 208 209 @Override getSmsCapacityOnIccForSubscriber(int subId)210 public int getSmsCapacityOnIccForSubscriber(int subId) { 211 throw new UnsupportedOperationException(); 212 } 213 } 214