com.onegini.sdk.model.Profile Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of idp-sdk Show documentation
Show all versions of idp-sdk Show documentation
Java SDK to connect to the Onegini platform
/*
* Copyright 2013-2020 Onegini b.v.
*
* Licensed 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 com.onegini.sdk.model;
import java.io.Serializable;
import java.util.Collection;
import java.util.Locale;
import org.joda.time.LocalDate;
/**
* The complete Profile of a person in Onegini
*
* @since {@literal 1}
*/
public interface Profile extends Serializable {
/**
* @return {@link Gender}, can be {@literal null}
*/
Gender getGender();
/**
* @return composite {@link Name} object for this Profile
*/
Name getName();
/**
* @return Collection of {@link EmailAddress}es for this Profile. Can be empty, not null.
*/
Collection getEmailAddresses();
/**
* @return Set of {@link PhoneNumber}s for this Profile. Can be empty, not null.
*/
Collection getPhoneNumbers();
/**
* @return Set of (postal) {@link Address}es for this Profile. Can be empty, not null.
*/
Collection getAddresses();
/**
* @return boolean, true when the profile contains one or more {@link Address}es that are of the alternative
* address type.
*/
boolean containsAlternativeAddress();
/**
* Timezone independent representation of a birth date, e.g. 1995-05-24
*
* @return {@link org.joda.time.LocalDate} instance of the birth date
*/
LocalDate getDateOfBirth();
/**
* @return preferred {@link Locale} to communicate
*/
Locale getPreferredLocale();
/**
* Required, unique identifier by which the Profile can be recognised after the Profile has been linked with a Onegini
* account.
*
* Is empty during the account link request.
*
* @return identifier
*/
String getReferenceId();
/**
* Optional, temporary identifier that can be used to recognise an existing user during the initial account link with
* Onegini.
*
* Will not be communicated after the account link request.
*
* @return temporary identifier
*/
String getMigrationCode();
/**
* @return Collection of {@link CustomAttribute}s, can be empty not null.
*/
Collection getCustomAttributes();
}