Class StockQuote

java.lang.Object
markets.alpaca.client.openapi.data.model.StockQuote
All Implemented Interfaces:
Serializable

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", comments="Generator version: 7.23.0") public class StockQuote extends Object implements Serializable
The best bid and ask information for a given security.
See Also:
  • Field Details

  • Constructor Details

    • StockQuote

      public StockQuote()
  • Method Details

    • ap

      public StockQuote ap(@Nonnull Double ap)
    • getAp

      @Nonnull public Double getAp()
      Ask price. 0 means the security has no active ask.
      Returns:
      ap
    • setAp

      public void setAp(@Nonnull Double ap)
    • as

      public StockQuote as(@Nonnull Integer as)
    • getAs

      @Nonnull public Integer getAs()
      Ask size in shares (round lots prior to November 3, 2025).
      Returns:
      as
    • setAs

      public void setAs(@Nonnull Integer as)
    • ax

      public StockQuote ax(@Nonnull String ax)
    • getAx

      @Nonnull public String getAx()
      Ask exchange. See `v2/stocks/meta/exchanges` for more details.
      Returns:
      ax
    • setAx

      public void setAx(@Nonnull String ax)
    • bp

      public StockQuote bp(@Nonnull Double bp)
    • getBp

      @Nonnull public Double getBp()
      Bid price. 0 means the security has no active bid.
      Returns:
      bp
    • setBp

      public void setBp(@Nonnull Double bp)
    • bs

      public StockQuote bs(@Nonnull Integer bs)
    • getBs

      @Nonnull public Integer getBs()
      Bid size in shares (round lots prior to November 3, 2025).
      Returns:
      bs
    • setBs

      public void setBs(@Nonnull Integer bs)
    • bx

      public StockQuote bx(@Nonnull String bx)
    • getBx

      @Nonnull public String getBx()
      Bid exchange. See `v2/stocks/meta/exchanges` for more details.
      Returns:
      bx
    • setBx

      public void setBx(@Nonnull String bx)
    • c

      public StockQuote c(@Nonnull List<String> c)
    • addCItem

      public StockQuote addCItem(String cItem)
    • getC

      @Nonnull public List<String> getC()
      Condition flags. See `v2/stocks/meta/conditions/quote` for more details. If the array contains one flag, it applies to both the bid and ask. If the array contains two flags, the first one applies to the bid and the second one to the ask.
      Returns:
      c
    • setC

      public void setC(@Nonnull List<String> c)
    • t

      public StockQuote t(@Nonnull OffsetDateTime t)
    • getT

      @Nonnull public OffsetDateTime getT()
      Timestamp in RFC-3339 format with nanosecond precision.
      Returns:
      t
    • setT

      public void setT(@Nonnull OffsetDateTime t)
    • z

      public StockQuote z(@Nonnull StockTape z)
    • getZ

      @Nonnull public StockTape getZ()
      Get z
      Returns:
      z
    • setZ

      public void setZ(@Nonnull StockTape z)
    • putAdditionalProperty

      public StockQuote putAdditionalProperty(String key, Object value)
      Set the additional (undeclared) property with the specified name and value. If the property does not already exist, create it otherwise replace it.
      Parameters:
      key - name of the property
      value - value of the property
      Returns:
      the StockQuote instance itself
    • getAdditionalProperties

      public Map<String,Object> getAdditionalProperties()
      Return the additional (undeclared) property.
      Returns:
      a map of objects
    • getAdditionalProperty

      public Object getAdditionalProperty(String key)
      Return the additional (undeclared) property with the specified name.
      Parameters:
      key - name of the property
      Returns:
      an object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • validateJsonElement

      public static void validateJsonElement(com.google.gson.JsonElement jsonElement) throws IOException
      Validates the JSON Element and throws an exception if issues found
      Parameters:
      jsonElement - JSON Element
      Throws:
      IOException - if the JSON Element is invalid with respect to StockQuote
    • fromJson

      public static StockQuote fromJson(String jsonString) throws IOException
      Create an instance of StockQuote given an JSON string
      Parameters:
      jsonString - JSON string
      Returns:
      An instance of StockQuote
      Throws:
      IOException - if the JSON string is invalid with respect to StockQuote
    • toJson

      public String toJson()
      Convert an instance of StockQuote to an JSON string
      Returns:
      JSON string