Enum NoopCallback

    • Enum Constant Detail

    • Method Detail

      • values

        public static NoopCallback[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (NoopCallback c : NoopCallback.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static NoopCallback valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null
      • supports

        public boolean supports​(Event event,
                                Context context)
        Description copied from interface: Callback
        Whether this callback supports this event or not. This is primarily meant as a way to optimize event handling by avoiding unnecessary connection state setups for events that will not be handled anyway.
        Specified by:
        supports in interface Callback
        Parameters:
        event - The event to check.
        context - The context for this event.
        Returns:
        true if it can be handled, false if not.
      • canHandleInTransaction

        public boolean canHandleInTransaction​(Event event,
                                              Context context)
        Description copied from interface: Callback
        Whether this event can be handled in a transaction or whether it must be handled outside a transaction instead. In the vast majority of the cases the answer will be true. Only in the rare cases where non-transactional statements are executed should this return false. This method is called before Callback.handle(Event, Context) in order to determine in advance whether a transaction can be used or not.
        Specified by:
        canHandleInTransaction in interface Callback
        Parameters:
        event - The event to check.
        context - The context for this event.
        Returns:
        true if it can be handled within a transaction (almost all cases). false if it must be handled outside a transaction instead (very rare).
      • handle

        public void handle​(Event event,
                           Context context)
        Description copied from interface: Callback
        Handles this MigrateDB lifecycle event.
        Specified by:
        handle in interface Callback
        Parameters:
        event - The event to handle.
        context - The context for this event.
      • getCallbackName

        public String getCallbackName()
        Description copied from interface: Callback
        The callback name, MigrateDB will use this to sort the callbacks alphabetically before executing them
        Specified by:
        getCallbackName in interface Callback
        Returns:
        The callback name