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

ch.openchvote.protocol.protocols.writein.content.message.MEE2 Maven / Gradle / Ivy

Go to download

This module instantiates the generic framework module to the CHVote protocol.

The newest version!
/*
 * Copyright (C) 2024 Berner Fachhochschule https://e-voting.bfh.ch
 *
 *  - This program is free software: you can redistribute it and/or modify                           -
 *  - it under the terms of the GNU Affero General Public License as published by                    -
 *  - the Free Software Foundation, either version 3 of the License, or                              -
 *  - (at your option) any later version.                                                            -
 *  -                                                                                                -
 *  - This program is distributed in the hope that it will be useful,                                -
 *  - but WITHOUT ANY WARRANTY; without even the implied warranty of                                 -
 *  - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the                                   -
 *  - GNU General Public License for more details.                                                   -
 *  -                                                                                                -
 *  - You should have received a copy of the GNU Affero General Public License                       -
 *  - along with this program. If not, see .                           -
 */
package ch.openchvote.protocol.protocols.writein.content.message;

import ch.openchvote.framework.annotations.content.Signed;
import ch.openchvote.framework.communication.Content;
import ch.openchvote.algorithms.protocols.common.model.CredentialProof;
import ch.openchvote.utilities.sequence.Vector;
import ch.openchvote.utilities.serializer.TypeReference;
import ch.openchvote.utilities.tuples.Quadruple;

import java.math.BigInteger;

@SuppressWarnings("MissingJavadoc")
@Signed
public final class MEE2 extends Quadruple, Vector, Vector, CredentialProof> implements Content {

    @SuppressWarnings("unused")
    static public final TypeReference TYPE_REFERENCE = new TypeReference<>() {
    };

    public MEE2(Vector bold_x_hat, Vector bold_y_hat, Vector bold_z_hat, CredentialProof pi_hat) {
        super(bold_x_hat, bold_y_hat, bold_z_hat, pi_hat);
    }

    public Vector get_bold_x_hat() {
        return this.getFirst();
    }

    public Vector get_bold_y_hat() {
        return this.getSecond();
    }

    public Vector get_bold_z_hat() {
        return this.getThird();
    }

    public CredentialProof get_pi_hat() {
        return this.getFourth();
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy