All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.groupbyinc.api.model.zone.RecordZone Maven / Gradle / Ivy

The newest version!
package com.groupbyinc.api.model.zone;

import com.groupbyinc.api.model.AbstractRecord;
import com.groupbyinc.api.model.Zone;

import java.util.List;

/**
 * 
 * Zone represents an area on the page that merchandisers have control over.  They can set the content
 * of a zone from the command center as part of a rule instantiation.  When a rule is triggered the zones are filled
 * in with the pertinent content.
 *
 * Zones contain the following properties:
 *
 * - `id`: an MD5 of the zone name
 * - `name`: the zone name
 * - `type`: `Records`: A list of zero or more records.
 * 
 * @author will
 */
public class RecordZone> extends Zone> {
    private String query;
    private List records;

    /**
     * 
     * Default constructor
     * 
     */
    public RecordZone() {
        // default constructor
    }

    /**
     * @internal
     * @return
     */
    @Override
    public Type getType() {
        return Type.Record;
    }

    /**
     * 
     * The query that was fired for this zone.
     * 
     *
     * @return The query that was fired for this zone.
     */
    public String getQuery() {
        return query;
    }

    /**
     * @param query Set the query
     * @return
     */
    public RecordZone setQuery(String query) {
        this.query = query;
        return this;
    }

    /**
     * 
     * A maximum of ten records will be returned for each record zone.
     * 
     *
     * @return A list of records returned from the search service.
     */
    public List getRecords() {
        return records;
    }

    /**
     * @param records Set the records
     * @return
     */
    public RecordZone setRecords(List records) {
        this.records = records;
        return this;
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy