本文整理汇总了Java中org.oscm.provisioning.data.User.getApplicationUserId方法的典型用法代码示例。如果您正苦于以下问题:Java User.getApplicationUserId方法的具体用法?Java User.getApplicationUserId怎么用?Java User.getApplicationUserId使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.oscm.provisioning.data.User
的用法示例。
在下文中一共展示了User.getApplicationUserId方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: validateUsers
import org.oscm.provisioning.data.User; //导入方法依赖的package包/类
/**
* Validates the applicationUserId of each {@link User} - it must not be
* longer than 255 characters.
*
* @param userList
* the list of {@link User}s to validate
* @param sub
* the {@link Subscription} to create the users for
* @throws TechnicalServiceOperationException
* in case of a to long application user id
*/
private static void validateUsers(List<User> userList, Subscription sub)
throws TechnicalServiceOperationException {
try {
for (User user : userList) {
if (user.getApplicationUserId() != null) {
BLValidator.isDescription("applicationUserId",
user.getApplicationUserId(), true);
}
}
} catch (ValidationException e) {
String message = "Invalid application user id with more than 255 characters returned.";
TechnicalServiceOperationException ex = new TechnicalServiceOperationException(
"Service createUsers() returned invalid data.",
new Object[] { sub.getSubscriptionId(), message }, e);
logger.logWarn(Log4jLogger.SYSTEM_LOG, ex,
LogMessageIdentifier.WARN_TECH_SERVICE_VALIDATION_FAILED_USERID_MAXLENGTH,
sub.getSubscriptionId());
throw ex;
}
}
示例2: mapApplicationUserIdToLicense
import org.oscm.provisioning.data.User; //导入方法依赖的package包/类
/**
* Maps the application user id back to the usage license and sets the
* affected usage license dirty
*
* @param licenses
* the usage licenses to update
* @param createdUsers
* the user array containing the application user id
*/
private void mapApplicationUserIdToLicense(List<UsageLicense> licenses,
User[] createdUsers) {
if (createdUsers == null) {
return;
}
String applicationUserId;
for (UsageLicense license : licenses) {
for (User createdUser : createdUsers) {
applicationUserId = createdUser.getApplicationUserId();
if (createdUser.getUserId()
.equals(license.getUser().getUserId())
&& applicationUserId != null) {
license.setApplicationUserId(applicationUserId);
break;
}
}
}
}
示例3: mapApplicationUserIdToLicense
import org.oscm.provisioning.data.User; //导入方法依赖的package包/类
/**
* Maps the application user id back to the usage license and sets the
* affected usage license dirty
*
* @param licenses
* the usage licenses to update
* @param createdUsers
* the user array containing the application user id
*/
private void mapApplicationUserIdToLicense(List<UsageLicense> licenses,
User[] createdUsers) {
if (createdUsers == null) {
return;
}
String applicationUserId;
for (UsageLicense license : licenses) {
for (User createdUser : createdUsers) {
applicationUserId = createdUser.getApplicationUserId();
if (createdUser.getUserId().equals(
license.getUser().getUserId())
&& applicationUserId != null) {
license.setApplicationUserId(applicationUserId);
break;
}
}
}
}