net.java.truelicense.swing.LicenseConsumerManagerEvent Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of truelicense-swing Show documentation
Show all versions of truelicense-swing Show documentation
The TrueLicense Swing module provides a graphical user interface for
consuming license keys.
/*
* Copyright (C) 2005-2013 Schlichtherle IT Services.
* All rights reserved. Use is subject to license terms.
*/
package net.java.truelicense.swing;
import java.util.EventObject;
import net.java.truelicense.core.LicenseConsumerManager;
/**
* Fired whenever a
* {@linkplain ObservableLicenseConsumerManager observable license consumer
* manager} has succeeded with an action.
*
* @author Christian Schlichtherle
*/
public final class LicenseConsumerManagerEvent extends EventObject {
private static final long serialVersionUID = 1L;
/**
* Constructs a new license consumer manager event.
*
* @param source the event source.
*/
public LicenseConsumerManagerEvent(
final ObservableLicenseConsumerManager source) {
super(source);
}
/** Returns the observable license consumer manager. */
@Override public ObservableLicenseConsumerManager getSource() {
return (ObservableLicenseConsumerManager) super.getSource();
}
/**
* Returns the delegate licence consumer manager - not the observable
* license consumer manager - so you can call
* {@link LicenseConsumerManager#view()} on it without generating another
* event.
*/
public final LicenseConsumerManager getDelegate() {
return getSource().delegate();
}
}