Record Class PushKeyFiles.ServiceAccountFile

java.lang.Object
java.lang.Record
com.iizix.push.PushKeyFiles.ServiceAccountFile
Record Components:
file - The file, absolute and normalized.
json - The JSON text, exactly as Google downloaded it. Never printed.
projectId - Its project_id, or null when absent.
clientEmail - Its client_email.
Enclosing class:
PushKeyFiles

public static record PushKeyFiles.ServiceAccountFile(Path file, String json, String projectId, String clientEmail) extends Record
A Firebase service-account key file as read.
Author:
Christopher Mindus
  • Constructor Details

    • ServiceAccountFile

      public ServiceAccountFile(Path file, String json, String projectId, String clientEmail)
      Creates an instance of a ServiceAccountFile record class.
      Parameters:
      file - the value for the file record component
      json - the value for the json record component
      projectId - the value for the projectId record component
      clientEmail - the value for the clientEmail record component
  • Method Details

    • toString

      public String toString()
      Never the JSON.
      Specified by:
      toString in class Record
      Returns:
      The file, the project and the account.
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • file

      public Path file()
      Returns the value of the file record component.
      Returns:
      the value of the file record component
    • json

      public String json()
      Returns the value of the json record component.
      Returns:
      the value of the json record component
    • projectId

      public String projectId()
      Returns the value of the projectId record component.
      Returns:
      the value of the projectId record component
    • clientEmail

      public String clientEmail()
      Returns the value of the clientEmail record component.
      Returns:
      the value of the clientEmail record component