📄 jxplorerevent.java
字号:
package com.ca.directory.jxplorer.event;
import java.util.EventObject;
/**
* The object that implements the <code>JXplorerListener</code> interface
* gets this <code>JXplorerEvent</code> when the event occurs.
*
* @see JXplorerListener
*
* @author Chris Betts
*/
public class JXplorerEvent extends EventObject {
/**
* The user selected DN being passed back in this event.
* @see getDN()
*/
private String DN;
private EventType type;
/**
* Constructs a <code>JXplorerEvent</code> object.
*
* @param source the object that originated the event
* @param id an integer that identifies the event
* @param command a string that may specify a command (possibly one
* of several) associated with the event
*/
public JXplorerEvent(Object source, EventType type, String DN)
{
super(source);
this.type = type;
this.DN = DN;
}
/**
* Returns the current DN.
*
* @return the selected DN (or null if none selected)
*/
public String getDN() {
return DN;
}
/**
* Gets the type of event.
*
* @return the type
*/
public EventType getEventType()
{
return type;
}
/**
* Defines the ENTERED, EXITED, and ACTIVATED event types, along
* with their string representations, returned by toString().
*/
public static final class EventType
{
private String typeString;
private EventType(String s)
{
typeString = s;
}
/**
* Entered type.
*/
public static final EventType DNSELECTED = new EventType("DNSELECTED");
/**
* Converts the type to a string.
*
* @return the string
*/
public String toString()
{
return typeString;
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -