Class CanceledInfo


  • public class CanceledInfo
    extends java.lang.Object
    Contains information about canceled build
    • Constructor Summary

      Constructors 
      Constructor Description
      CanceledInfo​(long userId, java.lang.String comment)
      Constructor for builds cancelled by a user
      CanceledInfo​(java.lang.String comment)
      Constructor for builds cancelled by the system
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getComment()
      Returns cancellation comment
      long getCreatedAt()  
      java.lang.Long getUserId()
      Returns id of the user who cancelled the build or null if build was not cancelled by a user
      boolean isCanceledByUser()
      Returns true if build was cancelled by a user
      boolean isOutdated()  
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • CanceledInfo

        public CanceledInfo​(long userId,
                            @Nullable
                            java.lang.String comment)
        Constructor for builds cancelled by a user
        Parameters:
        userId - id of the user who cancelled the build
        comment - comment
      • CanceledInfo

        public CanceledInfo​(@Nullable
                            java.lang.String comment)
        Constructor for builds cancelled by the system
        Parameters:
        comment - comment
    • Method Detail

      • getComment

        @Nullable
        public java.lang.String getComment()
        Returns cancellation comment
        Returns:
        cancellation comment
      • getUserId

        @Nullable
        public java.lang.Long getUserId()
        Returns id of the user who cancelled the build or null if build was not cancelled by a user
        Returns:
        user id who canceled the build
      • isCanceledByUser

        public boolean isCanceledByUser()
        Returns true if build was cancelled by a user
        Returns:
        true if the build was canceled by user
      • getCreatedAt

        public long getCreatedAt()
        Returns:
        the timestamp when this object was created
      • isOutdated

        public boolean isOutdated()
        Returns:
        true if this object was created (build was canceled) more than 5 minutes ago
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object