Class CopyrightToPlaceholderPopulator

  • All Implemented Interfaces:
    IPlaceholderPopulator

    class CopyrightToPlaceholderPopulator
    extends java.lang.Object
    implements IPlaceholderPopulator
    Class is used to populate copyrightTo placeholder. The resulting string is a representation of the last year of copyright years range. Among all products involved into product creation the latest copyrightTo year is picked as a resulting value
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String populate​(java.util.List<ConfirmedEventWrapper> events, java.lang.String parameter)
      Builds a replacement for a placeholder copyrightTo in accordance with the registered events.
      • Methods inherited from class java.lang.Object

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

      • CopyrightToPlaceholderPopulator

        public CopyrightToPlaceholderPopulator()
    • Method Detail

      • populate

        public java.lang.String populate​(java.util.List<ConfirmedEventWrapper> events,
                                         java.lang.String parameter)
        Builds a replacement for a placeholder copyrightTo in accordance with the registered events.
        Specified by:
        populate in interface IPlaceholderPopulator
        Parameters:
        events - is a list of event involved into document processing. It is expected that it is not empty as such cases should be handled by ProducerBuilder without calling any IPlaceholderPopulator
        parameter - is a parameter for the placeholder. It should be null as copyrightTo as the placeholder is not configurable
        Returns:
        the latest copyright year
        Throws:
        java.lang.IllegalArgumentException - if parameter is not null