Java 类javax.swing.text.PasswordView 实例源码
项目:cn1
文件:BasicPasswordFieldUI.java
public View create(final Element element) {
if (echoCharIsSet() || !getI18nProperty()) {
return new PasswordView(element);
} else {
return (View)AccessController.doPrivileged(new PrivilegedAction() {
public Object run() {
try {
Class cls = Class.forName(FIELD_VIEW_I18N_CLASS);
Constructor constructor =
cls.getConstructor(new Class[] {Element.class});
constructor.setAccessible(true);
return constructor.newInstance(new Object[] {element});
} catch (Exception e) {
return null;
}
}
});
}
}
项目:freeVM
文件:BasicPasswordFieldUI.java
public View create(final Element element) {
if (echoCharIsSet() || !getI18nProperty()) {
return new PasswordView(element);
} else {
return (View)AccessController.doPrivileged(new PrivilegedAction() {
public Object run() {
try {
Class cls = Class.forName(FIELD_VIEW_I18N_CLASS);
Constructor constructor =
cls.getConstructor(new Class[] {Element.class});
constructor.setAccessible(true);
return constructor.newInstance(new Object[] {element});
} catch (Exception e) {
return null;
}
}
});
}
}
项目:freeVM
文件:BasicPasswordFieldUI.java
public View create(final Element element) {
if (echoCharIsSet() || !getI18nProperty()) {
return new PasswordView(element);
} else {
return (View)AccessController.doPrivileged(new PrivilegedAction() {
public Object run() {
try {
Class cls = Class.forName(FIELD_VIEW_I18N_CLASS);
Constructor constructor =
cls.getConstructor(new Class[] {Element.class});
constructor.setAccessible(true);
return constructor.newInstance(new Object[] {element});
} catch (Exception e) {
return null;
}
}
});
}
}
项目:javify
文件:BasicPasswordFieldUI.java
public View create(Element elem)
{
return new PasswordView(elem);
}
项目:jvm-stm
文件:BasicPasswordFieldUI.java
public View create(Element elem)
{
return new PasswordView(elem);
}
项目:cn1
文件:BasicPasswordFieldUITest.java
public void testCreateElement() {
Element element = new PlainDocument().getDefaultRootElement();
assertTrue(ui.create(element) instanceof PasswordView);
}
项目:JamVM-PH
文件:BasicPasswordFieldUI.java
public View create(Element elem)
{
return new PasswordView(elem);
}
项目:classpath
文件:BasicPasswordFieldUI.java
public View create(Element elem)
{
return new PasswordView(elem);
}
项目:freeVM
文件:BasicPasswordFieldUITest.java
public void testCreateElement() {
Element element = new PlainDocument().getDefaultRootElement();
assertTrue(ui.create(element) instanceof PasswordView);
}
项目:freeVM
文件:BasicPasswordFieldUITest.java
public void testCreateElement() {
Element element = new PlainDocument().getDefaultRootElement();
assertTrue(ui.create(element) instanceof PasswordView);
}
项目:seaglass
文件:SeaGlassPasswordFieldUI.java
/**
* Creates a view (PasswordView) for an element.
*
* @param elem the element
*
* @return the view
*/
public View create(Element elem) {
return new PasswordView(elem);
}