001/** 002 * Copyright 2011 The Kuali Foundation Licensed under the 003 * Educational Community License, Version 2.0 (the "License"); you may 004 * not use this file except in compliance with the License. You may 005 * obtain a copy of the License at 006 * 007 * http://www.osedu.org/licenses/ECL-2.0 008 * 009 * Unless required by applicable law or agreed to in writing, 010 * software distributed under the License is distributed on an "AS IS" 011 * BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express 012 * or implied. See the License for the specific language governing 013 * permissions and limitations under the License. 014 */ 015 016package org.kuali.mobility.push.service; 017 018import java.util.List; 019 020import org.kuali.mobility.push.entity.Device; 021 022public interface DeviceService { 023 024 void registerDevice(Device device); 025 boolean removeDevice(Device device); 026 027 Long countDevices(); 028 int countIOSDevices(); 029 int countAndroidDevices(); 030 int countDevicesWithoutNetworkID(); 031 032 List<Device> findAllDevices(); 033 List<Device> findAlliOSDevices(); 034 List<Device> findAllAndroidDevices(); 035 036 boolean doesDeviceHaveUsername(String deviceid); 037 List<Device> findDevicesByUsername(String username); 038 039 List<Device> findDevicesWithoutUsername(); 040 List<Device> findDevicesById(String id); 041 List<Device> findDevicesByRegId(String regid); 042 List<Device> findDevicesByDeviceId(String deviceid); 043 044 Device findDeviceByDeviceId(String deviceid); 045 Device findDeviceById(Long id); 046 047}