from ..enums import LDEnum


class QueryViewType(LDEnum):
    """
    This describes the viewing mode of the Advanced Search Query expression.

        -"SIMPLE" For expressions with conditions that are all ANed or ORed together.
        -"COMPLEX" For expressions that combine conditions into logical clauses and mix AND and OR operators.
    """
    SIMPLE = "simple"
    COMPLEX = "complex"


class QueryFrequency(LDEnum):
    """
    This describes the frequency of execution of an Advanced Search Query.

        -"ONE_TIME" For executing queries only once.
        -"PERIODIC" For executing queries periodically.
    """
    ONE_TIME = "one_time"
    PERIODIC = "periodic"


class QueryCompoundReturnType(LDEnum):
    """
    This describes the type of compounds returned by an Advanced Search Query.

        -"BOTH" For returning results with both reals and virtuals.
        -"VIRTUAL_ONLY" For returning results with only virtuals.
        -"REAL_ONLY" For returning results with only reals.
    """
    BOTH = "both"
    VIRTUAL_ONLY = "virtual_only"
    REAL_ONLY = "real_only"


class QueryEntityReturnType(LDEnum):
    """
    This describes the type of entities returned by an Advanced Search Query.

        -"FORMULATION" For returning results with formulation entities.
        -"COMPOUND" For returning results with compound entities.
        -"FRAGMENT" For returning results with fragment entities.
    """
    FORMULATION = "formulation"
    COMPOUND = "compound"
    FRAGMENT = "fragment"


class QueryConditionType(LDEnum):
    """
    This describes the type of a query condition in an Advanced Search Query.

        -"OBSERVATION" For query conditions on observation columns.
        -"STRUCTURE" For query conditions on structures.
        -"PROJECT" For query conditions on projects.
        -"LIVE_REPORT" For query conditions on livereports.
    """
    OBSERVATION = "observation"
    STRUCTURE = "structure"
    PROJECT = "project"
    LIVE_REPORT = "live_report"


class QueryObservationConditionOperator(LDEnum):
    """
    This describes valid operators of an observation-type query condition in an Advanced Search Query
    """
    EQUALS = "="
    LESS_THAN = "<"
    LESS_THAN_OR_EQUALS = "<="
    GREATER_THAN = ">"
    GREATER_THAN_OR_EQUALS = ">="


class PlotMode(LDEnum):
    """
    This describes the Plot mode
    """
    BOX = "box"
    HEATMAP = "heatmap"
    HISTOGRAM = "histogram"
    LINE = "line"
    PIE = "pie"
    RADAR = "radar"
    SCATTER = "scatter"


class PlotType(LDEnum):
    """
    This describes the type of the plot
    """
    FORMS = "forms"
    VIZ = "viz"


class TooltipDisplayMode(LDEnum):
    """
    This describes the tooltip display mode of a plot
    """
    NORMAL = "normal"
    DOCKED = "docked"


class SizeByType(LDEnum):
    """
    This describes the size by type for a Plot 
    """
    COLUMN = "column"
    UNIFORM = "uniform"


class ShapeByType(LDEnum):
    """
    This describes the shape by type for a Plot
    """
    VALUE = "value"
    NUMERIC_RANGE = "numeric_range"


class BinType(LDEnum):
    """
    This describes the bin type for a Plot
    """
    BIN_COUNT = "bin_count"
    NUMERIC_RANGE = "numeric_range"
    ONE_PER_VALUE = "one_per_value"
    SMART = "smart"
    VALUE = "value"