// Licensed to the Apache Software Foundation (ASF) under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The ASF licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you may not use this file except in compliance // with the License. You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, // software distributed under the License is distributed on an // "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. package org.apache.cloudstack.query; import org.apache.cloudstack.affinity.AffinityGroupResponse; import org.apache.cloudstack.api.command.admin.host.ListHostsCmd; import org.apache.cloudstack.api.command.admin.internallb.ListInternalLBVMsCmd; import org.apache.cloudstack.api.command.admin.router.ListRoutersCmd; import org.apache.cloudstack.api.command.admin.storage.ListSecondaryStagingStoresCmd; import org.apache.cloudstack.api.command.admin.storage.ListImageStoresCmd; import org.apache.cloudstack.api.command.admin.storage.ListStoragePoolsCmd; import org.apache.cloudstack.api.command.admin.user.ListUsersCmd; import org.apache.cloudstack.api.command.user.account.ListAccountsCmd; import org.apache.cloudstack.api.command.user.account.ListProjectAccountsCmd; import org.apache.cloudstack.api.command.user.event.ListEventsCmd; import org.apache.cloudstack.api.command.user.iso.ListIsosCmd; import org.apache.cloudstack.api.command.user.job.ListAsyncJobsCmd; import org.apache.cloudstack.api.command.user.offering.ListDiskOfferingsCmd; import org.apache.cloudstack.api.command.user.offering.ListServiceOfferingsCmd; import org.apache.cloudstack.api.command.user.project.ListProjectInvitationsCmd; import org.apache.cloudstack.api.command.user.project.ListProjectsCmd; import org.apache.cloudstack.api.command.user.securitygroup.ListSecurityGroupsCmd; import org.apache.cloudstack.api.command.user.tag.ListTagsCmd; import org.apache.cloudstack.api.command.user.template.ListTemplatesCmd; import org.apache.cloudstack.api.command.user.vm.ListVMsCmd; import org.apache.cloudstack.api.command.user.vmgroup.ListVMGroupsCmd; import org.apache.cloudstack.api.command.user.volume.ListResourceDetailsCmd; import org.apache.cloudstack.api.command.user.volume.ListVolumesCmd; import org.apache.cloudstack.api.command.user.zone.ListZonesByCmd; import org.apache.cloudstack.api.response.*; import com.cloud.exception.PermissionDeniedException; import java.util.List; /** * Service used for list api query. * */ public interface QueryService { public ListResponse searchForUsers(ListUsersCmd cmd) throws PermissionDeniedException; public ListResponse searchForEvents(ListEventsCmd cmd); public ListResponse listTags(ListTagsCmd cmd); public ListResponse searchForVmGroups(ListVMGroupsCmd cmd); public ListResponse searchForUserVMs(ListVMsCmd cmd); public ListResponse searchForSecurityGroups(ListSecurityGroupsCmd cmd); public ListResponse searchForRouters(ListRoutersCmd cmd); public ListResponse listProjectInvitations(ListProjectInvitationsCmd cmd); public ListResponse listProjects(ListProjectsCmd cmd); public ListResponse listProjectAccounts(ListProjectAccountsCmd cmd); public ListResponse searchForServers(ListHostsCmd cmd); public ListResponse searchForVolumes(ListVolumesCmd cmd); public ListResponse searchForStoragePools(ListStoragePoolsCmd cmd); public ListResponse searchForImageStores(ListImageStoresCmd cmd); public ListResponse searchForSecondaryStagingStores(ListSecondaryStagingStoresCmd cmd); public ListResponse searchForAccounts(ListAccountsCmd cmd); public ListResponse searchForAsyncJobs(ListAsyncJobsCmd cmd); public ListResponse searchForDiskOfferings(ListDiskOfferingsCmd cmd); public ListResponse searchForServiceOfferings(ListServiceOfferingsCmd cmd); public ListResponse listDataCenters(ListZonesByCmd cmd); public ListResponse listTemplates(ListTemplatesCmd cmd); public ListResponse listIsos(ListIsosCmd cmd); public ListResponse listAffinityGroups(Long affinityGroupId, String affinityGroupName, String affinityGroupType, Long vmId, String accountName, Long domainId, boolean isRecursive, boolean listAll, Long startIndex, Long pageSize); public List listResourceDetails(ListResourceDetailsCmd cmd); ListResponse searchForInternalLbVms(ListInternalLBVMsCmd cmd); }