ComputeFHE 1.0
General-Purpose Privacy-Preserving Computation Library for TFHE
Loading...
Searching...
No Matches
Classes | Typedefs | Functions
Einteger.h File Reference

Defines the encrypted integer representation and operations. More...

#include <computefhe/CFHETypes.h>
#include <computefhe/FixedPoint.h>
#include <iostream>
Include dependency graph for Einteger.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  computefhe::Einteger
 Represents an encrypted integer. More...
 
class  computefhe::EInt< T, BITS, SIGNED >
 Template class for fixed-size encrypted integers. More...
 

Typedefs

using computefhe::Ebool = EInt< bool, 1, false >
 
using computefhe::Eint8 = EInt< int8_t, 8, true >
 Encrypted 8-bit signed integer.
 
using computefhe::Euint8 = EInt< uint8_t, 8, false >
 Encrypted 8-bit unsigned integer.
 
using computefhe::Eint16 = EInt< int16_t, 16, true >
 Encrypted 16-bit signed integer.
 
using computefhe::Euint16 = EInt< uint16_t, 16, false >
 Encrypted 16-bit unsigned integer.
 
using computefhe::Eint32 = EInt< int32_t, 32, true >
 Encrypted 32-bit signed integer.
 
using computefhe::Euint32 = EInt< uint32_t, 32, false >
 Encrypted 32-bit unsigned integer.
 
using computefhe::Eint64 = EInt< int64_t, 64, true >
 Encrypted 64-bit signed integer.
 
using computefhe::Euint64 = EInt< uint64_t, 64, false >
 Encrypted 64-bit unsigned integer.
 

Functions

ostreamcomputefhe::operator<< (ostream &out, const Einteger &obj)
 
const Einteger computefhe::operator== (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator!= (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator> (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator>= (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator< (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator<= (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator+ (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator- (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator* (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator/ (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator% (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator& (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator| (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator^ (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator&& (uint64_t a, const Einteger &b)
 
const Einteger computefhe::operator|| (uint64_t a, const Einteger &b)
 

Detailed Description

Defines the encrypted integer representation and operations.

Function Documentation

◆ operator!=()

const Einteger computefhe::operator!= ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
An Einteger representing the encrypted boolean result.

◆ operator%()

const Einteger computefhe::operator% ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
A new Einteger representing the remainder.

◆ operator&()

const Einteger computefhe::operator& ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
A new Einteger representing the bitwise AND.

◆ operator&&()

const Einteger computefhe::operator&& ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
An Einteger representing the encrypted boolean result.

◆ operator*()

const Einteger computefhe::operator* ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
A new Einteger representing the product.

◆ operator+()

const Einteger computefhe::operator+ ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
A new Einteger representing the sum.

◆ operator-()

const Einteger computefhe::operator- ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
A new Einteger representing the difference.

◆ operator/()

const Einteger computefhe::operator/ ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
A new Einteger representing the quotient.

◆ operator<()

const Einteger computefhe::operator< ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
An Einteger representing the encrypted boolean result.

◆ operator<<()

ostream & computefhe::operator<< ( ostream out,
const Einteger obj 
)
Parameters
outThe output stream.
objThe Einteger object to print.
Returns
The output stream.

◆ operator<=()

const Einteger computefhe::operator<= ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
An Einteger representing the encrypted boolean result.

◆ operator==()

const Einteger computefhe::operator== ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
An Einteger representing the encrypted boolean result.

◆ operator>()

const Einteger computefhe::operator> ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
An Einteger representing the encrypted boolean result.

◆ operator>=()

const Einteger computefhe::operator>= ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
An Einteger representing the encrypted boolean result.

◆ operator^()

const Einteger computefhe::operator^ ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
A new Einteger representing the bitwise XOR.

◆ operator|()

const Einteger computefhe::operator| ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
A new Einteger representing the bitwise OR.

◆ operator||()

const Einteger computefhe::operator|| ( uint64_t  a,
const Einteger b 
)
Parameters
aThe plaintext unsigned integer.
bThe encrypted integer.
Returns
An Einteger representing the encrypted boolean result.