org.jetbrains.kotlinx.ggdsl.dsl.columnScaled.kt Maven / Gradle / Ivy
/*
* Copyright 2020-2022 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license.
*/
package org.jetbrains.kotlinx.ggdsl.dsl
import org.jetbrains.kotlinx.ggdsl.ir.bindings.*
import org.jetbrains.kotlinx.ggdsl.ir.data.ColumnPointer
import org.jetbrains.kotlinx.ggdsl.ir.scale.NonPositionalScale
import org.jetbrains.kotlinx.ggdsl.ir.scale.NonPositionalUnspecifiedScale
import org.jetbrains.kotlinx.ggdsl.ir.scale.PositionalScale
import org.jetbrains.kotlinx.ggdsl.ir.scale.PositionalUnspecifiedScale
/**
* Applies the default (i.e. without specifying the type and parameters;
* they will be defined automatically; can be both used for positional and non-positional
* mappings) scale to this [ColumnPointer].
*
* @param DomainType type of the domain.
* @return scaled source.
*/
public fun ColumnPointer.scaled(): ColumnScaledUnspecifiedDefault =
ColumnScaledUnspecifiedDefault(this)
/**
* Applies an unspecified (i.e. without specifying the type and parameters;
* they will be defined automatically) positional scale to this [ColumnPointer].
*
* @param DomainType type of the domain.
* @param scale positional default scale.
* @return scaled source.
*/
public fun ColumnPointer.scaled(scale: PositionalUnspecifiedScale):
ColumnScaledPositionalUnspecified =
ColumnScaledPositionalUnspecified(this, scale)
/**
* Applies an unspecified (i.e. without specifying the type and parameters;
* they will be defined automatically) non-positional scale to this [ColumnPointer].
*
* @param DomainType type of the domain.
* @param scale non-positional default scale.
* @return scaled source.
*/
public fun ColumnPointer.scaled(scale: NonPositionalUnspecifiedScale):
ColumnScaledNonPositionalUnspecified =
ColumnScaledNonPositionalUnspecified(this, scale)
/**
* Applies a positional scale to this [ColumnPointer].
*
* @param DomainType type of the domain.
* @param scale positional scale.
* @return scaled source.
*/
public fun ColumnPointer.scaled(
scale: PositionalScale
): ColumnScaledPositional = ColumnScaledPositional(this, scale)
/**
* Applies a non-positional scale to this [ColumnPointer].
*
* @param DomainType type of the domain.
* @param scale non-positional scale.
* @return scaled source.
*/
public fun ColumnPointer.scaled(
scale: NonPositionalScale
): ColumnScaledNonPositional = ColumnScaledNonPositional(this, scale)
© 2015 - 2025 Weber Informatics LLC | Privacy Policy