// 
// Decompiled by Procyon v0.6.0
// 

package com.hypixel.hytale.builtin.hytalegenerator.positionproviders;

import com.hypixel.hytale.builtin.hytalegenerator.threadindexer.WorkerIndexer;
import javax.annotation.Nullable;
import com.hypixel.hytale.math.vector.Vector3d;
import java.util.function.Consumer;
import javax.annotation.Nonnull;

public abstract class PositionProvider
{
    public abstract void positionsIn(@Nonnull final Context p0);
    
    @Nonnull
    public static PositionProvider noPositionProvider() {
        return new PositionProvider() {
            @Override
            public void positionsIn(@Nonnull final Context context) {
            }
        };
    }
    
    public static class Context
    {
        public static final Consumer<Vector3d> EMPTY_CONSUMER;
        public Vector3d minInclusive;
        public Vector3d maxExclusive;
        public Consumer<Vector3d> consumer;
        @Nullable
        public Vector3d anchor;
        public WorkerIndexer.Id workerId;
        
        public Context() {
            this.minInclusive = Vector3d.ZERO;
            this.maxExclusive = Vector3d.ZERO;
            this.consumer = Context.EMPTY_CONSUMER;
            this.anchor = null;
            this.workerId = WorkerIndexer.Id.UNKNOWN;
        }
        
        public Context(@Nonnull final Vector3d minInclusive, @Nonnull final Vector3d maxExclusive, @Nonnull final Consumer<Vector3d> consumer, @Nullable final Vector3d anchor, final WorkerIndexer.Id workerId) {
            this.minInclusive = minInclusive;
            this.maxExclusive = maxExclusive;
            this.consumer = consumer;
            this.anchor = anchor;
            this.workerId = workerId;
        }
        
        public Context(@Nonnull final Context other) {
            this.minInclusive = other.minInclusive;
            this.maxExclusive = other.maxExclusive;
            this.consumer = other.consumer;
            this.anchor = other.anchor;
            this.workerId = other.workerId;
        }
        
        static {
            EMPTY_CONSUMER = (p -> {});
        }
    }
}
