/**
 * LogAnalytics API
 * The LogAnalytics API for the LogAnalytics service.

 * OpenAPI spec version: 20200601
 *
 *
 * NOTE: This class is auto generated by OracleSDKGenerator.
 * Do not edit the class manually.
 *
 * Copyright (c) 2020, 2022, Oracle and/or its affiliates.  All rights reserved.
 * This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
 */ import * as model from "../model" ; import common = require ( "oci-common" ) ; /**
 * Generic column defining all attributes common to all querylanguage columns.
 *
 */ export interface AbstractColumn { /**
     * Column display name - will be alias if column is renamed by queryStrng.
     *
     */ "displayName" ? : string ; /**
     * Subsystem column belongs to.
     *
     */ "subSystem" ? : model . SubSystemName ; /**
     * If the column is a 'List of Values' column, this array contains the field values that are applicable to query results or all if no filters applied.
     *
     */ "values" ? : Array < model . FieldValue > ; /**
     * Identifies if all values in this column come from a pre-defined list of values.
     *
     */ "isListOfValues" ? : boolean ; /**
     * Identifies if this column allows multiple values to exist in a single row.
     *
     */ "isMultiValued" ? : boolean ; /**
     * A flag indicating whether or not the field is a case sensitive field.  Only applies to string fields.
     *
     */ "isCaseSensitive" ? : boolean ; /**
     * Identifies if this column can be used as a grouping field in any grouping command.
     *
     */ "isGroupable" ? : boolean ; /**
     * Identifies if this column can be used as an expression parameter in any command that accepts querylanguage expressions.
     *
     */ "isEvaluable" ? : boolean ; /**
     * Field denoting column data type.
     *
     */ "valueType" ? : model . ValueType ; /**
     * Same as displayName unless column renamed in which case this will hold the original display name for the column.
     *
     */ "originalDisplayName" ? : string ; /**
     * Internal identifier for the column.
     *
     */ "internalName" ? : string ; "type" : string ; } export namespace AbstractColumn { export function getJsonObj ( obj ) { const jsonObj = { ... obj , ... { "values" : obj . values ? obj . values . map ( item => { return model . FieldValue . getJsonObj ( item ) ; } ) : undefined } } ; if ( "type" in obj && obj . type ) { switch ( obj . type ) { case "TIME_COLUMN" : return model . TimeColumn . getJsonObj ( < model . TimeColumn > ( < object > jsonObj ) , true ) ; case "CLASSIFY_COLUMN" : return model . ClassifyColumn . getJsonObj ( < model . ClassifyColumn > ( < object > jsonObj ) , true ) ; case "TREND_COLUMN" : return model . TrendColumn . getJsonObj ( < model . TrendColumn > ( < object > jsonObj ) , true ) ; case "COLUMN" : return model . Column . getJsonObj ( < model . Column > ( < object > jsonObj ) , true ) ; case "CHART_COLUMN" : return model . ChartColumn . getJsonObj ( < model . ChartColumn > ( < object > jsonObj ) , true ) ; case "CHART_DATA_COLUMN" : return model . ChartDataColumn . getJsonObj ( < model . ChartDataColumn > ( < object > jsonObj ) , true ) ; default : throw Error ( "Unknown value for: " + obj . type ) ; } } return jsonObj ; } export function getDeserializedJsonObj ( obj ) { const jsonObj = { ... obj , ... { "values" : obj . values ? obj . values . map ( item => { return model . FieldValue . getDeserializedJsonObj ( item ) ; } ) : undefined } } ; if ( "type" in obj && obj . type ) { switch ( obj . type ) { case "TIME_COLUMN" : return model . TimeColumn . getDeserializedJsonObj ( < model . TimeColumn > ( < object > jsonObj ) , true ) ; case "CLASSIFY_COLUMN" : return model . ClassifyColumn . getDeserializedJsonObj ( < model . ClassifyColumn > ( < object > jsonObj ) , true ) ; case "TREND_COLUMN" : return model . TrendColumn . getDeserializedJsonObj ( < model . TrendColumn > ( < object > jsonObj ) , true ) ; case "COLUMN" : return model . Column . getDeserializedJsonObj ( < model . Column > ( < object > jsonObj ) , true ) ; case "CHART_COLUMN" : return model . ChartColumn . getDeserializedJsonObj ( < model . ChartColumn > ( < object > jsonObj ) , true ) ; case "CHART_DATA_COLUMN" : return model . ChartDataColumn . getDeserializedJsonObj ( < model . ChartDataColumn > ( < object > jsonObj ) , true ) ; default : throw Error ( "Unknown value for: " + obj . type ) ; } } return jsonObj ; } }