Class Id

java.lang.Object
ru.bitel.common.model.Id
All Implemented Interfaces:
Serializable, Idable
Direct Known Subclasses:
AbstractBalanceBean, AbstractBillDocument, AbstractBonusBalanceBean, Account, AccountingPeriod, ActionLogEntry, AdditionalAgreement, AgentAVD, Attribute, Autopayment, BGAbstractTransaction, CardPacket, ConnectionLogEntry, Contact, ContractAutopayment, ContractLimitLog, ContractLimitMovement, ContractPattern, ContractPeriod, ContractStatus, ContractStatusLog, ContractTariff, ContractTariffGroup, ContractTariffOption, DataProcessRecord, DealerPayment, Device, DeviceInterfaceIndex, DevicePortSubscription, DispatchMessageStatistic, DocumentPositionSpec, DocumentStatusLogItem, Domain, DrwebAgentStatusBase, DrwebTariff, EnazaAccessToken, ForpostCameraBrand, ForpostCameraModel, ForpostCameraType, ForpostMaster, ForpostPtzType, ForpostRecordType, Gate, GateType, GroupRight, House, IdTitle, InetAccountingPeriod, InetAuthError, InetServRestriction, IpResource, IpResourceSubscription, IpResourceSubscriptionReal, LogEntry, MangoAccountProduct, MangoFee, MangoPhone, MegogoContractSubRequestLog, MegogoContractSubscriptionStatusPeriod, MobileContractData, MobileContractNotification, MobilePushToken, MobilePushTokenLink, MobileToken, PaymentInfo, PeriodicTask, PersonalDispatch, PhoneResource, PhoneResourceSubscription, Position, Product, ProductPeriod, ProductSpecServiceLink, Purchase, RCCdrItem, Rebill, RebillTransaction, RegistrationPeriod, RentsoftPayment, RentsoftProduct, Reserve, Revision, RSCMContractService, RunningTask, RunTelContractTariff, SbPilotPayment, SchedulerTaskLog, Service, ServiceObject, Session, SmartHouseIntercom, SmartHouseIntercomFlat, SmartHousePackageContract, SoftkeyTransaction, SoftLineSubscription, SormUploadStatistic, SqlHistoryRequest, SqlHistoryUserConfig, StatisticNote, SubscriberAccount, Subscription, Subscription, Subscription, Subscription, SynclogEntry, TariffGroupTariff, TrafficTypeLinkRule, TvServiceSpecChannelLink, UfanetAddressItem, UserCard, UserCardCopy, UserInfo, VlanResourceSubscription, VoiceAccountPort, VoiceAuthError, VoiceCostMapRange, VoiceError, VoiceGeographicRange, Zone, ZoneWhois

public class Id extends Object implements Serializable, Idable
See Also:
  • Field Details

    • id

      protected int id
      id объекта
  • Constructor Details

    • Id

      public Id()
    • Id

      protected Id(int id)
  • Method Details

    • getId

      public int getId()
      Возвращает id объекта
      Specified by:
      getId in interface Idable
      Returns:
    • setId

      public void setId(int value)
      Устанавливает id объекта
      Parameters:
      value - id
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • newMap

      public static <K extends Id> Map<Integer,K> newMap(List<K> list)
    • newIdSet

      public static <K extends Id> Set<Integer> newIdSet(K[] list)
    • newIdSet

      public static Set<Integer> newIdSet(Collection<? extends Id> list)
    • newIdSet

      public static <K extends Id> Set<Integer> newIdSet(K entity)
      Получить из Set из одного Id для объекта. Бывает нужно когда у нас всего один объект, а нужно передать список id.
      Parameters:
      entity -
      Returns:
    • newIdSet

      public static Set<Integer> newIdSet(List<? extends Id> list)
    • newIdList

      public static List<Integer> newIdList(Collection<? extends Id> list)
      Список ид из списка сущностей.
      Parameters:
      list - коллекция объектов дочерних Id.
      Returns:
      список целых чисел в порядке итерации исходной коллекции.
      See Also:
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • copyTo

      public void copyTo(Id id)