public class AVACL extends Object
| 构造器和说明 |
|---|
AVACL() |
AVACL(AVACL other) |
AVACL(AVUser owner) |
AVACL(HashMap data) |
AVACL(com.alibaba.fastjson.JSONObject json) |
| 限定符和类型 | 方法和说明 |
|---|---|
boolean |
equals(Object o) |
Map<String,cn.leancloud.AVACL.Permissions> |
getPermissionsById() |
boolean |
getPublicReadAccess()
Get whether the public is allowed to read this object.
|
boolean |
getPublicWriteAccess()
Set whether the public is allowed to write this object.
|
boolean |
getReadAccess(AVUser user) |
boolean |
getReadAccess(String userId)
Get whether the given user id is *explicitly* allowed to read this object.
|
boolean |
getRoleReadAccess(String role) |
boolean |
getRoleWriteAccess(String role) |
boolean |
getWriteAccess(AVUser user) |
boolean |
getWriteAccess(String userId)
Get whether the given user id is *explicitly* allowed to write this object.
|
int |
hashCode() |
void |
setPublicReadAccess(boolean allowed)
Set whether the public is allowed to read this object.
|
void |
setPublicWriteAccess(boolean allowed)
Set whether the public is allowed to write this object.
|
void |
setReadAccess(AVUser user,
boolean allowed) |
void |
setReadAccess(String userId,
boolean allowed)
Set whether the given user id is allowed to read this object.
|
void |
setRoleReadAccess(String role,
boolean allowed) |
void |
setRoleWriteAccess(String role,
boolean allowed) |
void |
setWriteAccess(AVUser user,
boolean allowed) |
void |
setWriteAccess(String userId,
boolean allowed)
Set whether the given user id is allowed to write this object.
|
com.alibaba.fastjson.JSONObject |
toJSONObject() |
public AVACL()
public AVACL(com.alibaba.fastjson.JSONObject json)
public AVACL(HashMap data)
public AVACL(AVACL other)
public AVACL(AVUser owner)
public com.alibaba.fastjson.JSONObject toJSONObject()
public void setPublicReadAccess(boolean allowed)
allowed - flag to allow.public boolean getPublicReadAccess()
public void setPublicWriteAccess(boolean allowed)
allowed - flag to allowpublic boolean getPublicWriteAccess()
public void setReadAccess(String userId, boolean allowed)
userId - target user id.allowed - flag to allowpublic boolean getReadAccess(String userId)
false, the user may still be able to access it if getPublicReadAccess returns
true or a role that the user belongs to has read access.public void setWriteAccess(String userId, boolean allowed)
public boolean getWriteAccess(String userId)
false, the user may still be able to write it if getPublicWriteAccess returns
true or a role that the user belongs to has write access.public void setReadAccess(AVUser user, boolean allowed)
public boolean getReadAccess(AVUser user)
public void setWriteAccess(AVUser user, boolean allowed)
public boolean getWriteAccess(AVUser user)
public void setRoleReadAccess(String role, boolean allowed)
public boolean getRoleReadAccess(String role)
public void setRoleWriteAccess(String role, boolean allowed)
public boolean getRoleWriteAccess(String role)
Copyright © 2019. All rights reserved.