Class DeviceSession.Builder

java.lang.Object
com.dropbox.core.v2.team.DeviceSession.Builder
Direct Known Subclasses:
ActiveWebSession.Builder, DesktopClientSession.Builder, MobileClientSession.Builder
Enclosing class:
DeviceSession

public static class DeviceSession.Builder extends Object
Builder for DeviceSession.
  • Field Details

    • sessionId

      protected final String sessionId
    • ipAddress

      protected String ipAddress
    • country

      protected String country
    • created

      protected Date created
    • updated

      protected Date updated
  • Constructor Details

    • Builder

      protected Builder(String sessionId)
  • Method Details

    • withIpAddress

      public DeviceSession.Builder withIpAddress(String ipAddress)
      Set value for optional field.
      Parameters:
      ipAddress - The IP address of the last activity from this session.
      Returns:
      this builder
    • withCountry

      public DeviceSession.Builder withCountry(String country)
      Set value for optional field.
      Parameters:
      country - The country from which the last activity from this session was made.
      Returns:
      this builder
    • withCreated

      public DeviceSession.Builder withCreated(Date created)
      Set value for optional field.
      Parameters:
      created - The time this session was created.
      Returns:
      this builder
    • withUpdated

      public DeviceSession.Builder withUpdated(Date updated)
      Set value for optional field.
      Parameters:
      updated - The time of the last activity from this session.
      Returns:
      this builder
    • build

      public DeviceSession build()
      Builds an instance of DeviceSession configured with this builder's values
      Returns:
      new instance of DeviceSession