private EndpointProfileDataDto convert(EndpointProfileDto profileDto) { return new EndpointProfileDataDto( profileDto.getId(), endpointKey, profileDto.getClientProfileVersion(), profileDto.getClientProfileBody(), profileDto.getServerProfileVersion(), profileDto.getServerProfileBody()); }
@Override public EndpointUserDto toDto() { EndpointUserDto dto = new EndpointUserDto(); dto.setId(id); dto.setUsername(username); dto.setExternalId(externalId); dto.setTenantId(tenantId); dto.setAccessToken(accessToken); dto.setEndpointIds(endpointIds); dto.setVersion(version); return dto; }
@Override public EndpointUserConfigurationDto toDto() { EndpointUserConfigurationDto dto = new EndpointUserConfigurationDto(); dto.setAppToken(appToken); dto.setBody(body); dto.setSchemaVersion(schemaVersion); dto.setUserId(userId); return dto; } }
/** * Create new instance of <code>CassandraEndpointUserConfiguration</code>. * * @param dto data transfer object contain data that * assign on fields of new instance */ public CassandraEndpointUserConfiguration(EndpointUserConfigurationDto dto) { this.userId = dto.getUserId(); this.appToken = dto.getAppToken(); this.schemaVersion = dto.getSchemaVersion(); this.body = dto.getBody(); }
/** * Convert unicast notification. * * @param unicastNotification the unicast notification * @return the notification dto */ private NotificationDto convertUnicastNotification(EndpointNotificationDto unicastNotification) { NotificationDto dto = unicastNotification.getNotificationDto(); dto.setId(unicastNotification.getId()); return dto; }
@Override public EventClassFamilyVersionStateDto toDto() { EventClassFamilyVersionStateDto dto = new EventClassFamilyVersionStateDto(); dto.setEcfId(ecfId); dto.setVersion(version); return dto; }
@SuppressWarnings("unchecked") @Override protected K getObjectId(T value) { if (value != null && value instanceof HasId) { return (K) ((HasId) value).getId(); } else { return null; } }
@Override public String getValue(EndpointProfileDto item) { return item.getServerProfileVersion() + ""; } }, 80);
/** * Instantiates a new ConfigurationDto. * @param other the ConfigurationDto object */ public ConfigurationDto(ConfigurationDto other) { super(other); this.schemaId = other.schemaId; this.schemaVersion = other.getSchemaVersion(); this.protocolSchema = other.protocolSchema; }
@Override public String getValue(EndpointProfileDto item) { return item.getLogSchemaVersion() + ""; } }, 80);
@Override public String getValue(T item) { return item.getName(); } },
@Override public String getValue(T item) { return item.getVersion() + ""; } },
/** * Instantiates the NotificationSchema. */ public NotificationSchema(NotificationSchemaDto dto) { super(dto); if (dto != null) { this.type = dto.getType(); } }
@Override public String getValue(ProfileFilterRecordDto item) { return item.getServerProfileSchemaVersion() != null ? item.getServerProfileSchemaVersion() + "" : ""; } }, 60);
@Override public int hashCode() { return super.hashCode(); } }
@Override public boolean equals(Object obj) { if (this == obj) { return true; } if (!(obj instanceof LogSchemaDto)) { return false; } return super.equals(obj); }
/** * Create new instance of <code>MongoEndpointUserConfiguration</code>. * @param dto data transfer object contain data that * assign on fields of new instance */ public MongoEndpointUserConfiguration(EndpointUserConfigurationDto dto) { this.userId = dto.getUserId(); this.appToken = dto.getAppToken(); this.schemaVersion = dto.getSchemaVersion(); this.body = dto.getBody(); this.id = userId + ID_DELIMITER + appToken + ID_DELIMITER + schemaVersion; }