![JAR search and dependency download from the Maven repository](/logo.png)
com.day.cq.security.resource.UserResource Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of aem-sdk-api Show documentation
Show all versions of aem-sdk-api Show documentation
The Adobe Experience Manager SDK
/*
* Copyright 1997-2008 Day Management AG
* Barfuesserplatz 6, 4001 Basel, Switzerland
* All Rights Reserved.
*
* This software is the confidential and proprietary information of
* Day Management AG, ("Confidential Information"). You shall not
* disclose such Confidential Information and shall use it only in
* accordance with the terms of the license agreement you entered into
* with Day.
*/
package com.day.cq.security.resource;
import com.day.cq.security.User;
import org.apache.sling.api.resource.ResourceResolver;
/**
* UserResource class.
*
* @deprecated 5.4
*/
public class UserResource extends AuthorizableResource {
/**
* Constructor for UserResource.
*
* @param user a {@link com.day.cq.security.User} object.
* @param path a {@link java.lang.String} object.
* @param resolver a {@link org.apache.sling.api.resource.ResourceResolver} object.
*/
public UserResource(User user, String path, ResourceResolver resolver) {
super(user, path, resolver);
}
/**
* Sets the Resource-Type to com.day.cq.security.resource.User
*
* @see org.apache.sling.api.resource.Resource#getResourceType()
* @return a {@link java.lang.String} object.
*/
public String getResourceType() {
return User.class.getName();
}
/**
* Sets the Resource-SuperType to com.day.cq.security.resource.AuthorizableResource
*
* @see org.apache.sling.api.resource.Resource#getResourceSuperType()
* @return a {@link java.lang.String} object.
*/
public String getResourceSuperType() {
return super.getResourceType();
}
/**
* {@inheritDoc}
*
* Adds adapter-support for the {@link com.day.cq.security.User User}
* @see org.apache.sling.api.resource.Resource#getResourceSuperType()
*/
@SuppressWarnings("unchecked")
public AdapterType adaptTo(Class type) {
if (type == User.class) {
return (AdapterType) getAuthorizable();
}
return super.adaptTo(type);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy