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

com.paritytrading.parity.match.Order Maven / Gradle / Ivy

There is a newer version: 0.7.0
Show newest version
package com.paritytrading.parity.match;

class Order {

    private Level parent;

    private long id;

    private long remainingQuantity;

    public Order(Level parent, long id, long size) {
        this.parent = parent;

        this.id = id;

        this.remainingQuantity = size;
    }

    public long getId() {
        return id;
    }

    public long getRemainingQuantity() {
        return remainingQuantity;
    }

    public void reduce(long quantity) {
        remainingQuantity -= quantity;
    }

    public void resize(long size) {
        remainingQuantity = size;
    }

    public void delete() {
        parent.delete(this);
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy