T - type of bindingpublic class DefaultBinding<T> extends Object implements Binding<T>
Binding.EnableBinding| Modifier and Type | Field and Description |
|---|---|
protected String |
group |
protected org.springframework.context.Lifecycle |
lifecycle |
protected String |
name |
protected T |
target |
| Constructor and Description |
|---|
DefaultBinding(String name,
String group,
T target,
org.springframework.context.Lifecycle lifecycle)
Creates an instance that associates a given name, group and binding target with an
optional
Lifecycle component, which will be stopped during unbinding. |
DefaultBinding(String name,
T target,
org.springframework.context.Lifecycle lifecycle) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
afterUnbind()
Listener method that executes after unbinding.
|
String |
getBindingName()
Returns the name of the target for this binding (i.e., channel name).
|
String |
getGroup() |
String |
getName()
Returns the name of the destination for this binding.
|
String |
getState() |
boolean |
isPausable() |
boolean |
isPaused() |
boolean |
isRunning() |
void |
pause()
Pauses the target component represented by this instance if and only if the
component implements
Pausable interface NOTE: At the time the instance is
created the component is already started and active. |
void |
resume()
Resumes the target component represented by this instance if and only if the
component implements
Pausable interface NOTE: At the time the instance is
created the component is already started and active. |
void |
start()
Stops the target component represented by this instance.
|
void |
stop()
Starts the target component represented by this instance.
|
String |
toString() |
void |
unbind()
Unbinds the target component represented by this instance and stops any active
components.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetExtendedInfo, isInputprotected final String name
protected final String group
protected final T target
protected final org.springframework.context.Lifecycle lifecycle
public DefaultBinding(String name, String group, T target, org.springframework.context.Lifecycle lifecycle)
Lifecycle component, which will be stopped during unbinding.name - the name of the binding targetgroup - the group (only for input targets)target - the binding targetlifecycle - Lifecycle that runs while the binding is active and will
be stopped during unbindingpublic String getName()
Bindingpublic String getBindingName()
BindinggetBindingName in interface Binding<T>public String getGroup()
public String getState()
public boolean isRunning()
isRunning in interface Binding<T>isRunning in interface org.springframework.context.LifecycleisRunning in interface org.springframework.integration.support.management.ManageableLifecyclepublic boolean isPausable()
public boolean isPaused()
isPaused in interface org.springframework.integration.core.Pausablepublic void start()
Bindingstart in interface Binding<T>start in interface org.springframework.context.Lifecyclestart in interface org.springframework.integration.support.management.ManageableLifecycleBindingsEndpointpublic void stop()
Bindingstop in interface Binding<T>stop in interface org.springframework.context.Lifecyclestop in interface org.springframework.integration.support.management.ManageableLifecycleBindingsEndpointpublic void pause()
BindingPausable interface NOTE: At the time the instance is
created the component is already started and active. This operation is typically
used by actuator to pause/resume.pause in interface Binding<T>pause in interface org.springframework.integration.core.PausableBindingsEndpointpublic void resume()
BindingPausable interface NOTE: At the time the instance is
created the component is already started and active. This operation is typically
used by actuator to pause/resume.resume in interface Binding<T>resume in interface org.springframework.integration.core.PausableBindingsEndpointpublic void unbind()
Bindingprotected void afterUnbind()
Copyright © 2021 Pivotal Software, Inc.. All rights reserved.