package com.xmomen.module.core.web.token;

import org.apache.shiro.authc.UsernamePasswordToken;

public class SysUserToken extends UsernamePasswordToken {

	// 定义序列化版本号
	private static final long serialVersionUID = 1L;

	// 定义领域键
	private final String realmKey = "UserRealm";
	
	// 构造函数，传入用户名、密码、是否记住我、主机
	public SysUserToken(final String username, final String password,
            final boolean rememberMe, final String host) {
		// 调用父类构造函数，传入用户名、密码、是否记住我、主机
		super(username, password != null ? password.toCharArray() : null, rememberMe, host);
	}
	
	// 获取领域键
	public String getRealmKey() {
		return this.realmKey;
	}
}
