package com.easyagents.search.engine.service;

public class KeywordSearchRequest {

    private String keyword;
    private int count = 10;
    private String knowledgeId;

    public static KeywordSearchRequest of(String keyword, int count) {
        KeywordSearchRequest request = new KeywordSearchRequest();
        request.setKeyword(keyword);
        request.setCount(count);
        return request;
    }

    public String getKeyword() {
        return keyword;
    }

    public void setKeyword(String keyword) {
        this.keyword = keyword;
    }

    public int getCount() {
        return count;
    }

    public void setCount(int count) {
        this.count = count <= 0 ? 10 : count;
    }

    public String getKnowledgeId() {
        return knowledgeId;
    }

    public void setKnowledgeId(String knowledgeId) {
        this.knowledgeId = knowledgeId;
    }
}
