code stringlengths 73 34.1k | label stringclasses 1
value |
|---|---|
@Override
public Object put(List<Map.Entry> batch) throws InterruptedException {
if (initializeClusterSource()) {
return clusterSource.put(batch);
}
return null;
} | java |
public <T> T eval(ELVars vars, String el, Class<T> returnType) throws ELEvalException {
Utils.checkNotNull(vars, "vars");
Utils.checkNotNull(el, "expression");
Utils.checkNotNull(returnType, "returnType");
VARIABLES_IN_SCOPE_TL.set(vars);
try {
return evaluate(vars, el, returnType);
} fin... | java |
public String getLinkCopyText(JSONObject jsonObject){
if(jsonObject == null) return "";
try {
JSONObject copyObject = jsonObject.has("copyText") ? jsonObject.getJSONObject("copyText") : null;
if(copyObject != null){
return copyObject.has("text") ? copyObject.getS... | java |
public String getLinkUrl(JSONObject jsonObject){
if(jsonObject == null) return null;
try {
JSONObject urlObject = jsonObject.has("url") ? jsonObject.getJSONObject("url") : null;
if(urlObject == null) return null;
JSONObject androidObject = urlObject.has("android") ?... | java |
public String getLinkColor(JSONObject jsonObject){
if(jsonObject == null) return null;
try {
return jsonObject.has("color") ? jsonObject.getString("color") : "";
} catch (JSONException e) {
Logger.v("Unable to get Link Text Color with JSON - "+e.getLocalizedMessage());
... | java |
static void onActivityCreated(Activity activity) {
// make sure we have at least the default instance created here.
if (instances == null) {
CleverTapAPI.createInstanceIfAvailable(activity, null);
}
if (instances == null) {
Logger.v("Instances is null in onActivi... | java |
static void handleNotificationClicked(Context context,Bundle notification) {
if (notification == null) return;
String _accountId = null;
try {
_accountId = notification.getString(Constants.WZRK_ACCT_ID_KEY);
} catch (Throwable t) {
// no-op
}
if ... | java |
public static @Nullable CleverTapAPI getInstance(Context context) throws CleverTapMetaDataNotFoundException, CleverTapPermissionsNotSatisfied {
// For Google Play Store/Android Studio tracking
sdkVersion = BuildConfig.SDK_VERSION_STRING;
return getDefaultInstance(context);
} | java |
@SuppressWarnings("WeakerAccess")
public static @Nullable CleverTapAPI getDefaultInstance(Context context) {
// For Google Play Store/Android Studio tracking
sdkVersion = BuildConfig.SDK_VERSION_STRING;
if (defaultConfig == null) {
ManifestInfo manifest = ManifestInfo.getInstance... | java |
private void destroySession() {
currentSessionId = 0;
setAppLaunchPushed(false);
getConfigLogger().verbose(getAccountId(),"Session destroyed; Session ID is now 0");
clearSource();
clearMedium();
clearCampaign();
clearWzrkParams();
} | java |
private String FCMGetFreshToken(final String senderID) {
String token = null;
try {
if(senderID != null){
getConfigLogger().verbose(getAccountId(), "FcmManager: Requesting a FCM token with Sender Id - "+senderID);
token = FirebaseInstanceId.getInstance().getTo... | java |
private String GCMGetFreshToken(final String senderID) {
getConfigLogger().verbose(getAccountId(), "GcmManager: Requesting a GCM token for Sender ID - " + senderID);
String token = null;
try {
token = InstanceID.getInstance(context)
.getToken(senderID, GoogleCloud... | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public void setOffline(boolean value){
offline = value;
if (offline) {
getConfigLogger().debug(getAccountId(), "CleverTap Instance has been set to offline, won't send events queue");
} else {
getConfigLogger().debug(getAcc... | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public void enableDeviceNetworkInfoReporting(boolean value){
enableNetworkInfoReporting = value;
StorageHelper.putBoolean(context,storageKeyWithSuffix(Constants.NETWORK_INFO),enableNetworkInfoReporting);
getConfigLogger().verbose(getAccountId(), ... | java |
@SuppressWarnings("unused")
public String getDevicePushToken(final PushType type) {
switch (type) {
case GCM:
return getCachedGCMToken();
case FCM:
return getCachedFCMToken();
default:
return null;
}
} | java |
private void attachMeta(final JSONObject o, final Context context) {
// Memory consumption
try {
o.put("mc", Utils.getMemoryConsumption());
} catch (Throwable t) {
// Ignore
}
// Attach the network type
try {
o.put("nt", Utils.getCurre... | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public void recordScreen(String screenName){
if(screenName == null || (!currentScreenName.isEmpty() && currentScreenName.equals(screenName))) return;
getConfigLogger().debug(getAccountId(), "Screen changed to " + screenName);
currentScreenName = ... | java |
private void clearQueues(final Context context) {
synchronized (eventLock) {
DBAdapter adapter = loadDBAdapter(context);
DBAdapter.Table tableName = DBAdapter.Table.EVENTS;
adapter.removeEvents(tableName);
tableName = DBAdapter.Table.PROFILE_EVENTS;
... | java |
private QueueCursor updateCursorForDBObject(JSONObject dbObject, QueueCursor cursor) {
if (dbObject == null) return cursor;
Iterator<String> keys = dbObject.keys();
if (keys.hasNext()) {
String key = keys.next();
cursor.setLastId(key);
try {
... | java |
private JSONObject getARP(final Context context) {
try {
final String nameSpaceKey = getNamespaceARPKey();
if (nameSpaceKey == null) return null;
final SharedPreferences prefs = StorageHelper.getPreferences(context, nameSpaceKey);
final Map<String, ?> all = prefs... | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public int getTotalVisits() {
EventDetail ed = getLocalDataStore().getEventDetail(Constants.APP_LAUNCHED_EVENT);
if (ed != null) return ed.getCount();
return 0;
} | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public int getTimeElapsed() {
int currentSession = getCurrentSession();
if (currentSession == 0) return -1;
int now = (int) (System.currentTimeMillis() / 1000);
return now - currentSession;
} | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public UTMDetail getUTMDetails() {
UTMDetail ud = new UTMDetail();
ud.setSource(source);
ud.setMedium(medium);
ud.setCampaign(campaign);
return ud;
} | java |
private void _handleMultiValues(ArrayList<String> values, String key, String command) {
if (key == null) return;
if (values == null || values.isEmpty()) {
_generateEmptyMultiValueError(key);
return;
}
ValidationResult vr;
// validate the key
vr ... | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public void pushEvent(String eventName) {
if (eventName == null || eventName.trim().equals(""))
return;
pushEvent(eventName, null);
} | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public void pushNotificationViewedEvent(Bundle extras){
if (extras == null || extras.isEmpty() || extras.get(Constants.NOTIFICATION_TAG) == null) {
getConfigLogger().debug(getAccountId(), "Push notification: " + (extras == null ? "NULL" : extras.toS... | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public int getCount(String event) {
EventDetail eventDetail = getLocalDataStore().getEventDetail(event);
if (eventDetail != null) return eventDetail.getCount();
return -1;
} | java |
private void pushDeviceToken(final String token, final boolean register, final PushType type) {
pushDeviceToken(this.context, token, register, type);
} | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public static NotificationInfo getNotificationInfo(final Bundle extras) {
if (extras == null) return new NotificationInfo(false, false);
boolean fromCleverTap = extras.containsKey(Constants.NOTIFICATION_TAG);
boolean shouldRender = fromCleverTap... | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public void pushInstallReferrer(Intent intent) {
try {
final Bundle extras = intent.getExtras();
// Preliminary checks
if (extras == null || !extras.containsKey("referrer")) {
return;
}
... | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public synchronized void pushInstallReferrer(String source, String medium, String campaign) {
if (source == null && medium == null && campaign == null) return;
try {
// If already pushed, don't send it again
int status = StorageHe... | java |
@SuppressWarnings("unused")
public static void changeCredentials(String accountID, String token) {
changeCredentials(accountID, token, null);
} | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public static void changeCredentials(String accountID, String token, String region) {
if(defaultConfig != null){
Logger.i("CleverTap SDK already initialized with accountID:"+defaultConfig.getAccountId()
+" and token:"+defaultConfi... | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public int getInboxMessageCount(){
synchronized (inboxControllerLock) {
if (this.ctInboxController != null) {
return ctInboxController.count();
} else {
getConfigLogger().debug(getAccountId(),"Notification ... | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public int getInboxMessageUnreadCount(){
synchronized (inboxControllerLock) {
if (this.ctInboxController != null) {
return ctInboxController.unreadCount();
} else {
getConfigLogger().debug(getAccountId(), "... | java |
@SuppressWarnings({"unused", "WeakerAccess"})
public void markReadInboxMessage(final CTInboxMessage message){
postAsyncSafely("markReadInboxMessage", new Runnable() {
@Override
public void run() {
synchronized (inboxControllerLock) {
if(ctInboxCont... | java |
boolean advance() {
if (header.frameCount <= 0) {
return false;
}
if(framePointer == getFrameCount() - 1) {
loopIndex++;
}
if(header.loopCount != LOOP_FOREVER && loopIndex > header.loopCount) {
return false;
}
framePointer = ... | java |
int getDelay(int n) {
int delay = -1;
if ((n >= 0) && (n < header.frameCount)) {
delay = header.frames.get(n).delay;
}
return delay;
} | java |
boolean setFrameIndex(int frame) {
if(frame < INITIAL_FRAME_POINTER || frame >= getFrameCount()) {
return false;
}
framePointer = frame;
return true;
} | java |
int read(InputStream is, int contentLength) {
if (is != null) {
try {
int capacity = (contentLength > 0) ? (contentLength + 4096) : 16384;
ByteArrayOutputStream buffer = new ByteArrayOutputStream(capacity);
int nRead;
byte[] data = new ... | java |
synchronized int read(byte[] data) {
this.header = getHeaderParser().setData(data).parseHeader();
if (data != null) {
setData(header, data);
}
return status;
} | java |
private void readChunkIfNeeded() {
if (workBufferSize > workBufferPosition) {
return;
}
if (workBuffer == null) {
workBuffer = bitmapProvider.obtainByteArray(WORK_BUFFER_SIZE);
}
workBufferPosition = 0;
workBufferSize = Math.min(rawData.remaining()... | java |
@TargetApi(Build.VERSION_CODES.ICE_CREAM_SANDWICH)
public static synchronized void register(android.app.Application application) {
if (application == null) {
Logger.i("Application instance is null/system API is too old");
return;
}
if (registered) {
Logge... | java |
ValidationResult cleanObjectKey(String name) {
ValidationResult vr = new ValidationResult();
name = name.trim();
for (String x : objectKeyCharsNotAllowed)
name = name.replace(x, "");
if (name.length() > Constants.MAX_KEY_LENGTH) {
name = name.substring(0, Constan... | java |
ValidationResult cleanMultiValuePropertyKey(String name) {
ValidationResult vr = cleanObjectKey(name);
name = (String) vr.getObject();
// make sure its not a known property key (reserved in the case of multi-value)
try {
RestrictedMultiValueFields rf = RestrictedMultiValue... | java |
ValidationResult isRestrictedEventName(String name) {
ValidationResult error = new ValidationResult();
if (name == null) {
error.setErrorCode(510);
error.setErrorDesc("Event Name is null");
return error;
}
for (String x : restrictedNames)
i... | java |
private ValidationResult _mergeListInternalForKey(String key, JSONArray left,
JSONArray right, boolean remove, ValidationResult vr) {
if (left == null) {
vr.setObject(null);
return vr;
}
if (right == null) {
... | java |
@SuppressWarnings({"WeakerAccess"})
protected void initDeviceID() {
getDeviceCachedInfo(); // put this here to avoid running on main thread
// generate a provisional while we do the rest async
generateProvisionalGUID();
// grab and cache the googleAdID in any event if available
... | java |
static void i(String message){
if (getStaticDebugLevel() >= CleverTapAPI.LogLevel.INFO.intValue()){
Log.i(Constants.CLEVERTAP_LOG_TAG,message);
}
} | java |
String calculateDisplayTimestamp(long time){
long now = System.currentTimeMillis()/1000;
long diff = now-time;
if(diff < 60){
return "Just Now";
}else if(diff > 60 && diff < 59*60){
return (diff/(60)) + " mins ago";
}else if(diff > 59*60 && diff < 23*59*60... | java |
public void setTabs(ArrayList<String>tabs) {
if (tabs == null || tabs.size() <= 0) return;
if (platformSupportsTabs) {
ArrayList<String> toAdd;
if (tabs.size() > MAX_TABS) {
toAdd = new ArrayList<>(tabs.subList(0, MAX_TABS));
} else {
... | java |
@Deprecated
@SuppressWarnings("deprecation")
public void push(String eventName, HashMap<String, Object> chargeDetails,
ArrayList<HashMap<String, Object>> items)
throws InvalidEventNameException {
// This method is for only charged events
if (!eventName.equals(Con... | java |
public ArrayList<String> getCarouselImages(){
ArrayList<String> carouselImages = new ArrayList<>();
for(CTInboxMessageContent ctInboxMessageContent: getInboxMessageContents()){
carouselImages.add(ctInboxMessageContent.getMedia());
}
return carouselImages;
} | java |
synchronized int storeObject(JSONObject obj, Table table) {
if (!this.belowMemThreshold()) {
Logger.v("There is not enough space left on the device to store data, data discarded");
return DB_OUT_OF_MEMORY_ERROR;
}
final String tableName = table.getName();
Cursor... | java |
synchronized long storeUserProfile(String id, JSONObject obj) {
if (id == null) return DB_UPDATE_ERROR;
if (!this.belowMemThreshold()) {
getConfigLogger().verbose("There is not enough space left on the device to store data, data discarded");
return DB_OUT_OF_MEMORY_ERROR;
... | java |
synchronized void removeUserProfile(String id) {
if (id == null) return;
final String tableName = Table.USER_PROFILES.getName();
try {
final SQLiteDatabase db = dbHelper.getWritableDatabase();
db.delete(tableName, "_id = ?", new String[]{id});
} catch (final SQLi... | java |
synchronized void removeEvents(Table table) {
final String tName = table.getName();
try {
final SQLiteDatabase db = dbHelper.getWritableDatabase();
db.delete(tName, null, null);
} catch (final SQLiteException e) {
getConfigLogger().verbose("Error removing all... | java |
synchronized JSONObject fetchEvents(Table table, final int limit) {
final String tName = table.getName();
Cursor cursor = null;
String lastId = null;
final JSONArray events = new JSONArray();
//noinspection TryFinallyCanBeTryWithResources
try {
final SQLiteD... | java |
synchronized void storeUninstallTimestamp() {
if (!this.belowMemThreshold()) {
getConfigLogger().verbose("There is not enough space left on the device to store data, data discarded");
return ;
}
final String tableName = Table.UNINSTALL_TS.getName();
try {
... | java |
synchronized boolean deleteMessageForId(String messageId, String userId){
if(messageId == null || userId == null) return false;
final String tName = Table.INBOX_MESSAGES.getName();
try {
final SQLiteDatabase db = dbHelper.getWritableDatabase();
db.delete(tName, _ID + " ... | java |
synchronized boolean markReadMessageForId(String messageId, String userId){
if(messageId == null || userId == null) return false;
final String tName = Table.INBOX_MESSAGES.getName();
try{
final SQLiteDatabase db = dbHelper.getWritableDatabase();
ContentValues cv = new Co... | java |
synchronized ArrayList<CTMessageDAO> getMessages(String userId){
final String tName = Table.INBOX_MESSAGES.getName();
Cursor cursor;
ArrayList<CTMessageDAO> messageDAOArrayList = new ArrayList<>();
try{
final SQLiteDatabase db = dbHelper.getWritableDatabase();
cur... | java |
private void readContents(int maxFrames) {
// Read GIF file content blocks.
boolean done = false;
while (!(done || err() || header.frameCount > maxFrames)) {
int code = read();
switch (code) {
// Image separator.
case 0x2C:
... | java |
private void readBitmap() {
// (sub)image position & size.
header.currentFrame.ix = readShort();
header.currentFrame.iy = readShort();
header.currentFrame.iw = readShort();
header.currentFrame.ih = readShort();
int packed = read();
// 1 - local color table flag i... | java |
private void readNetscapeExt() {
do {
readBlock();
if (block[0] == 1) {
// Loop count sub-block.
int b1 = ((int) block[1]) & 0xff;
int b2 = ((int) block[2]) & 0xff;
header.loopCount = (b2 << 8) | b1;
if(heade... | java |
private void readLSD() {
// Logical screen size.
header.width = readShort();
header.height = readShort();
// Packed fields
int packed = read();
// 1 : global color table flag.
header.gctFlag = (packed & 0x80) != 0;
// 2-4 : color resolution.
// 5 :... | java |
private int[] readColorTable(int ncolors) {
int nbytes = 3 * ncolors;
int[] tab = null;
byte[] c = new byte[nbytes];
try {
rawData.get(c);
// Max size to avoid bounds checks.
tab = new int[MAX_BLOCK_SIZE];
int i = 0;
int j = 0... | java |
private void skip() {
try {
int blockSize;
do {
blockSize = read();
rawData.position(rawData.position() + blockSize);
} while (blockSize > 0);
} catch (IllegalArgumentException ex) {
}
} | java |
private int read() {
int curByte = 0;
try {
curByte = rawData.get() & 0xFF;
} catch (Exception e) {
header.status = GifDecoder.STATUS_FORMAT_ERROR;
}
return curByte;
} | java |
private boolean isToIgnore(CtElement element) {
if (element instanceof CtStatementList && !(element instanceof CtCase)) {
if (element.getRoleInParent() == CtRole.ELSE || element.getRoleInParent() == CtRole.THEN) {
return false;
}
return true;
}
return element.isImplicit() || element instanceof CtRefe... | java |
public JsonObject getJSONwithOperations(TreeContext context, ITree tree, List<Operation> operations) {
OperationNodePainter opNodePainter = new OperationNodePainter(operations);
Collection<NodePainter> painters = new ArrayList<NodePainter>();
painters.add(opNodePainter);
return getJSONwithCustorLabels(context,... | java |
public List<Action> getRootActions() {
final List<Action> rootActions = srcUpdTrees.stream().map(t -> originalActionsSrc.get(t))
.collect(Collectors.toList());
rootActions.addAll(srcDelTrees.stream() //
.filter(t -> !srcDelTrees.contains(t.getParent()) && !srcUpdTrees.contains(t.getParent())) //
.map(t... | java |
public Diff compare(File f1, File f2) throws Exception {
return this.compare(getCtType(f1), getCtType(f2));
} | java |
public Diff compare(String left, String right) {
return compare(getCtType(left), getCtType(right));
} | java |
public Diff compare(CtElement left, CtElement right) {
final SpoonGumTreeBuilder scanner = new SpoonGumTreeBuilder();
return new DiffImpl(scanner.getTreeContext(), scanner.getTree(left), scanner.getTree(right));
} | java |
public void set(int index, T object) {
synchronized (mLock) {
if (mOriginalValues != null) {
mOriginalValues.set(index, object);
} else {
mObjects.set(index, object);
}
}
if (mNotifyOnChange) notifyDataSetChanged();
} | java |
public void addAll(int index, T... items) {
List<T> collection = Arrays.asList(items);
synchronized (mLock) {
if (mOriginalValues != null) {
mOriginalValues.addAll(index, collection);
} else {
mObjects.addAll(index, collection);
}
... | java |
public void removeAt(int index) {
synchronized (mLock) {
if (mOriginalValues != null) {
mOriginalValues.remove(index);
} else {
mObjects.remove(index);
}
}
if (mNotifyOnChange) notifyDataSetChanged();
} | java |
public boolean removeAll(Collection<?> collection) {
boolean result = false;
synchronized (mLock) {
Iterator<?> it;
if (mOriginalValues != null) {
it = mOriginalValues.iterator();
} else {
it = mObjects.iterator();
}
... | java |
public void addAll(@NonNull final Collection<T> collection) {
final int length = collection.size();
if (length == 0) {
return;
}
synchronized (mLock) {
final int position = getItemCount();
mObjects.addAll(collection);
notifyItemRangeInserte... | java |
@Nullable
public T getItem(final int position) {
if (position < 0 || position >= mObjects.size()) {
return null;
}
return mObjects.get(position);
} | java |
public void replaceItem(@NonNull final T oldObject, @NonNull final T newObject) {
synchronized (mLock) {
final int position = getPosition(oldObject);
if (position == -1) {
// not found, don't replace
return;
}
mObjects.remove(posit... | java |
@TargetApi(VERSION_CODES.KITKAT)
public static void hideSystemUI(Activity activity) {
// Set the IMMERSIVE flag.
// Set the content to appear under the system bars so that the content
// doesn't resize when the system bars hideSelf and show.
View decorView = activity.getWindow().getD... | java |
@TargetApi(VERSION_CODES.KITKAT)
public static void showSystemUI(Activity activity) {
View decorView = activity.getWindow().getDecorView();
decorView.setSystemUiVisibility(
View.SYSTEM_UI_FLAG_LAYOUT_STABLE
| View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION
... | java |
@Override
public View getView(int position, View convertView,
ViewGroup parent) {
return (wrapped.getView(position, convertView, parent));
} | java |
@Override
public void onDismiss(DialogInterface dialog) {
if (mOldDialog != null && mOldDialog == dialog) {
// This is the callback from the old progress dialog that was already dismissed before
// the device orientation change, so just ignore it.
return;
}
... | java |
public static boolean isToStringMethod(Method method) {
return (method != null && method.getName().equals("readString") && method.getParameterTypes().length == 0);
} | java |
public static Method[] getUniqueDeclaredMethods(Class<?> leafClass) throws IllegalArgumentException {
final List<Method> methods = new ArrayList<Method>(32);
doWithMethods(leafClass, new MethodCallback() {
@Override
public void doWith(Method method) {
boolean know... | java |
@Override
public V put(K key, V value) {
if (fast) {
synchronized (this) {
Map<K, V> temp = cloneMap(map);
V result = temp.put(key, value);
map = temp;
return (result);
}
} else {
synchroniz... | java |
@Override
public void putAll(Map<? extends K, ? extends V> in) {
if (fast) {
synchronized (this) {
Map<K, V> temp = cloneMap(map);
temp.putAll(in);
map = temp;
}
} else {
synchronized (map) {
... | java |
@Override
public V remove(Object key) {
if (fast) {
synchronized (this) {
Map<K, V> temp = cloneMap(map);
V result = temp.remove(key);
map = temp;
return (result);
}
} else {
synchronized (m... | java |
public static boolean isFileExist(String filePath) {
if (StringUtils.isEmpty(filePath)) {
return false;
}
File file = new File(filePath);
return (file.exists() && file.isFile());
} | java |
public static boolean isFolderExist(String directoryPath) {
if (StringUtils.isEmpty(directoryPath)) {
return false;
}
File dire = new File(directoryPath);
return (dire.exists() && dire.isDirectory());
} | java |
public static void addToMediaStore(Context context, File file) {
String[] path = new String[]{file.getPath()};
MediaScannerConnection.scanFile(context, path, null, null);
} | java |
@Override
public synchronized long skip(final long length) throws IOException {
final long skip = super.skip(length);
this.count += skip;
return skip;
} | java |
public final void notifyHeaderItemRangeInserted(int positionStart, int itemCount) {
int newHeaderItemCount = getHeaderItemCount();
if (positionStart < 0 || itemCount < 0 || positionStart + itemCount > newHeaderItemCount) {
throw new IndexOutOfBoundsException("The given range [" + positionSta... | java |
public final void notifyHeaderItemChanged(int position) {
if (position < 0 || position >= headerItemCount) {
throw new IndexOutOfBoundsException("The given position " + position + " is not within the position bounds for header items [0 - " + (headerItemCount - 1) + "].");
}
notifyIte... | java |
public final void notifyHeaderItemRangeChanged(int positionStart, int itemCount) {
if (positionStart < 0 || itemCount < 0 || positionStart + itemCount >= headerItemCount) {
throw new IndexOutOfBoundsException("The given range [" + positionStart + " - " + (positionStart + itemCount - 1) + "] is not w... | java |
public void notifyHeaderItemMoved(int fromPosition, int toPosition) {
if (fromPosition < 0 || toPosition < 0 || fromPosition >= headerItemCount || toPosition >= headerItemCount) {
throw new IndexOutOfBoundsException("The given fromPosition " + fromPosition + " or toPosition " + toPosition + " is not... | java |
public void notifyHeaderItemRangeRemoved(int positionStart, int itemCount) {
if (positionStart < 0 || itemCount < 0 || positionStart + itemCount > headerItemCount) {
throw new IndexOutOfBoundsException("The given range [" + positionStart + " - " + (positionStart + itemCount - 1) + "] is not within t... | java |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.