Code example for ContentValues

Methods: size

0
            return (mBefore == null) && (mAfter == null);
        } 
 
        public boolean isUpdate() { 
            // When "after" has some changes, action is "update" 
            return beforeExists() && (mAfter != null && mAfter.size() > 0);
        } 
 
        public boolean isNoop() { 
            // When "after" has no changes, action is no-op 
            return beforeExists() && (mAfter != null && mAfter.size() == 0);
        } 
 
        public boolean isInsert() { 
            // When no "before" id, and has "after", action is "insert" 
            return !beforeExists() && (mAfter != null);
        } 
 
        public void markDeleted() { 
            mAfter = null;
        }