Clearmatics Libsnark
0.1
C++ library for zkSNARK proofs
|
#include <variable.hpp>
Public Member Functions | |
virtual FElemInterface & | operator= (const long n)=0 |
virtual FElemInterface & | operator= (const FConst &src)=0 |
virtual ::std::string | asString () const =0 |
virtual FieldType | fieldType () const =0 |
virtual FElemInterface & | operator+= (const FElemInterface &other)=0 |
virtual FElemInterface & | operator-= (const FElemInterface &other)=0 |
virtual FElemInterface & | operator*= (const FElemInterface &other)=0 |
virtual bool | operator== (const FElemInterface &other) const =0 |
virtual bool | operator== (const FConst &other) const =0 |
virtual bool | operator== (const long n) const =0 |
virtual FElemInterfacePtr | clone () const =0 |
virtual FElemInterfacePtr | inverse () const =0 |
virtual long | asLong () const =0 |
virtual int | getBit (unsigned int i) const =0 |
virtual FElemInterface & | power (long exponent)=0 |
virtual | ~FElemInterface () |
An interface class for field elements. Currently 2 classes will derive from this interface: R1P_Elem - Elements of a field of prime characteristic FConst - Formally not a field, only placeholders for field agnostic constants, such as 0 and 1. Can be used for -1 or any other constant which makes semantic sense in all fields.
Definition at line 53 of file variable.hpp.
|
inlinevirtual |
Definition at line 78 of file variable.hpp.
|
pure virtual |
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
FConst will be field agnostic, allowing us to hold values such as 0 and 1 without knowing the underlying field. This assignment operator will convert to the correct field element.
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
This operator is not always mathematically well defined. 'n' will be checked in runtime for fields in which integer values are not well defined.
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.
|
pure virtual |
Implemented in gadgetlib2::R1P_Elem, and gadgetlib2::FConst.