Class Request
java.lang.Object
com.sk89q.worldedit.session.request.Request
Describes the current request using a
ThreadLocal
.-
Method Summary
Modifier and TypeMethodDescriptiongetActor()
static Collection
<Request> getAll()
Get theEditSession
.Get the request session.getWorld()
Get the request world.boolean
isValid()
Check if the current request object is still valid.static Request
request()
Get the current request, which is specific to the current thread.static void
reset()
Reset the current request and clear all fields.void
void
setEditSession
(EditSession editSession) Set theEditSession
.void
void
setSession
(LocalSession session) Get the request session.void
Set the request world.
-
Method Details
-
getAll
-
getWorld
Get the request world.- Returns:
- the world, which may be null
-
setWorld
Set the request world.- Parameters:
world
- the world, which may be null
-
setExtent
-
getExtent
-
getActor
-
setActor
-
getSession
Get the request session.- Returns:
- the session, which may be null
-
setSession
Get the request session.- Parameters:
session
- the session, which may be null
-
getEditSession
Get theEditSession
.- Returns:
- the edit session, which may be null
-
setEditSession
Set theEditSession
.- Parameters:
editSession
- the edit session, which may be null
-
request
Get the current request, which is specific to the current thread.- Returns:
- the current request
-
reset
public static void reset()Reset the current request and clear all fields. -
isValid
public boolean isValid()Check if the current request object is still valid. Invalid requests may contain outdated values.- Returns:
- true if the request is valid
-