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

io.github.humbleui.skija.SurfaceProps Maven / Gradle / Ivy

There is a newer version: 0.116.2
Show newest version
// Generated by delombok at Mon Dec 20 14:13:09 UTC 2021
package io.github.humbleui.skija;

import lombok.*;
import org.jetbrains.annotations.*;
import io.github.humbleui.skija.impl.*;

public class SurfaceProps {
    @ApiStatus.Internal
    public final boolean _deviceIndependentFonts;
    @ApiStatus.Internal
    public final PixelGeometry _pixelGeometry;

    public SurfaceProps() {
        this(false, PixelGeometry.UNKNOWN);
    }

    public SurfaceProps(PixelGeometry geo) {
        this(false, geo);
    }

    @ApiStatus.Internal
    public int _getFlags() {
        return 0 | (_deviceIndependentFonts ? 1 : 0);
    }

    @ApiStatus.Internal
    public int _getPixelGeometryOrdinal() {
        return _pixelGeometry.ordinal();
    }

    @java.lang.SuppressWarnings("all")
    public boolean isDeviceIndependentFonts() {
        return this._deviceIndependentFonts;
    }

    @java.lang.SuppressWarnings("all")
    public PixelGeometry getPixelGeometry() {
        return this._pixelGeometry;
    }

    @java.lang.Override
    @java.lang.SuppressWarnings("all")
    public boolean equals(final java.lang.Object o) {
        if (o == this) return true;
        if (!(o instanceof SurfaceProps)) return false;
        final SurfaceProps other = (SurfaceProps) o;
        if (!other.canEqual((java.lang.Object) this)) return false;
        if (this.isDeviceIndependentFonts() != other.isDeviceIndependentFonts()) return false;
        final java.lang.Object this$_pixelGeometry = this.getPixelGeometry();
        final java.lang.Object other$_pixelGeometry = other.getPixelGeometry();
        if (this$_pixelGeometry == null ? other$_pixelGeometry != null : !this$_pixelGeometry.equals(other$_pixelGeometry)) return false;
        return true;
    }

    @java.lang.SuppressWarnings("all")
    protected boolean canEqual(final java.lang.Object other) {
        return other instanceof SurfaceProps;
    }

    @java.lang.Override
    @java.lang.SuppressWarnings("all")
    public int hashCode() {
        final int PRIME = 59;
        int result = 1;
        result = result * PRIME + (this.isDeviceIndependentFonts() ? 79 : 97);
        final java.lang.Object $_pixelGeometry = this.getPixelGeometry();
        result = result * PRIME + ($_pixelGeometry == null ? 43 : $_pixelGeometry.hashCode());
        return result;
    }

    @java.lang.Override
    @java.lang.SuppressWarnings("all")
    public java.lang.String toString() {
        return "SurfaceProps(_deviceIndependentFonts=" + this.isDeviceIndependentFonts() + ", _pixelGeometry=" + this.getPixelGeometry() + ")";
    }

    /**
     * @return {@code this}.
     */
    @java.lang.SuppressWarnings("all")
    public SurfaceProps withDeviceIndependentFonts(final boolean _deviceIndependentFonts) {
        return this._deviceIndependentFonts == _deviceIndependentFonts ? this : new SurfaceProps(_deviceIndependentFonts, this._pixelGeometry);
    }

    /**
     * @return {@code this}.
     */
    @java.lang.SuppressWarnings("all")
    public SurfaceProps withPixelGeometry(final PixelGeometry _pixelGeometry) {
        return this._pixelGeometry == _pixelGeometry ? this : new SurfaceProps(this._deviceIndependentFonts, _pixelGeometry);
    }

    @java.lang.SuppressWarnings("all")
    public SurfaceProps(final boolean deviceIndependentFonts, final PixelGeometry pixelGeometry) {
        this._deviceIndependentFonts = deviceIndependentFonts;
        this._pixelGeometry = pixelGeometry;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy