Class MarketNewsCacheKeys

java.lang.Object
com.bluebell.greenhouse.platform.configuration.cache.market.news.MarketNewsCacheKeys

public final class MarketNewsCacheKeys extends Object
Cache key helpers for market news lookups.
Version:
3.0.3
Author:
Stephen Prizio
  • Method Details

    • forSearch

      public static String forSearch(String symbol, String[] tags, LocalDate start, LocalDate end, Integer limit, Integer offset)
      Builds the cache key for a combined market news search.
      Parameters:
      symbol - optional symbol
      tags - optional topic tags
      start - optional start date
      end - optional end date
      limit - optional result limit
      offset - optional result offset
      Returns:
      cache key
    • forArticleUrl

      public static String forArticleUrl(String articleUrl)
      Builds the cache key for a market news article image lookup.
      Parameters:
      articleUrl - article URL
      Returns:
      cache key
    • forSummary

      public static String forSummary(String article, int maxSentences)
      Builds a bounded cache key for a market news article summary.
      Parameters:
      article - article content
      maxSentences - maximum number of summary sentences
      Returns:
      cache key