Package net.minecraftforge.permissions

Examples of net.minecraftforge.permissions.PermissionContext


    private void listUserPermissions(UserIdent ident)
    {
        if (tabCompleteMode)
            return;

        if (!tabCompleteMode && !PermissionsManager.checkPermission(new PermissionContext().setCommandSender(sender), PERM_LIST_PERMS))
        {
            OutputHandler.chatError(sender, FEPermissions.MSG_NO_COMMAND_PERM);
            return;
        }
View Full Code Here


        }
    }

    private void listGroups()
    {
        if (!tabCompleteMode && !PermissionsManager.checkPermission(new PermissionContext().setCommandSender(sender), PERM_LIST_GROUPS))
        {
            OutputHandler.chatError(sender, FEPermissions.MSG_NO_COMMAND_PERM);
            return;
        }
        info("Groups:");
View Full Code Here

        }
    }

    private void listUsers()
    {
        if (!tabCompleteMode && !PermissionsManager.checkPermission(new PermissionContext().setCommandSender(sender), PERM_LIST_USERS))
        {
            OutputHandler.chatError(sender, FEPermissions.MSG_NO_COMMAND_PERM);
            return;
        }
        info("Known players:");
View Full Code Here

        if (senderPlayer == null)
        {
            error(FEPermissions.MSG_NO_CONSOLE_COMMAND);
            return;
        }
        if (!tabCompleteMode && !PermissionsManager.checkPermission(new PermissionContext().setCommandSender(sender), PERM_TEST))
        {
            OutputHandler.chatError(sender, FEPermissions.MSG_NO_COMMAND_PERM);
            return;
        }
        if (tabCompleteMode)
View Full Code Here

    // -- User
    // ------------------------------------------------------------

    private void parseUser()
    {
        if (!tabCompleteMode && !PermissionsManager.checkPermission(new PermissionContext().setCommandSender(sender), PERM_USER))
        {
            error(FEPermissions.MSG_NO_COMMAND_PERM);
            return;
        }
        if (args.isEmpty())
View Full Code Here

        }
    }

    private void parseUserPrefixSuffix(UserIdent ident, Zone zone, boolean isSuffix)
    {
        if (!tabCompleteMode && !PermissionsManager.checkPermission(new PermissionContext().setCommandSender(sender), PERM_USER_FIX))
        {
            OutputHandler.chatError(sender, FEPermissions.MSG_NO_COMMAND_PERM);
            return;
        }
        if (tabCompleteMode)
View Full Code Here

        }
    }

    private void parseUserPermissions(UserIdent ident, Zone zone, PermissionAction type)
    {
        if (!tabCompleteMode && !PermissionsManager.checkPermission(new PermissionContext().setCommandSender(sender), PERM_USER_PERMS))
        {
            OutputHandler.chatError(sender, FEPermissions.MSG_NO_COMMAND_PERM);
            return;
        }
        if (args.isEmpty())
View Full Code Here

        }
    }

    private void parseUserSpawn(UserIdent ident, Zone zone)
    {
        if (!tabCompleteMode && !PermissionsManager.checkPermission(new PermissionContext().setCommandSender(sender), PERM_USER_SPAWN))
        {
            throw new CommandException(FEPermissions.MSG_NO_COMMAND_PERM);
        }
        if (args.isEmpty())
        {
View Full Code Here

    // -- Group
    // ------------------------------------------------------------

    private void parseGroup()
    {
        if (!tabCompleteMode && !PermissionsManager.checkPermission(new PermissionContext().setCommandSender(sender), PERM_GROUP))
        {
            OutputHandler.chatError(sender, FEPermissions.MSG_NO_COMMAND_PERM);
            return;
        }
        if (args.isEmpty())
View Full Code Here

        parseGroupInner(group, null);
    }

    private void parseGlobal()
    {
        if (!tabCompleteMode && !PermissionsManager.checkPermission(new PermissionContext().setCommandSender(sender), PERM_GROUP))
        {
            OutputHandler.chatError(sender, FEPermissions.MSG_NO_COMMAND_PERM);
            return;
        }
        if (args.isEmpty())
View Full Code Here

TOP

Related Classes of net.minecraftforge.permissions.PermissionContext

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.