package
0.0.0-20190516140124-028b8ad327b1
Repository: https://github.com/jacobmoxham/partiiprojectimplementation.git
Documentation: pkg.go.dev

# Packages

No description provided by the author

# Functions

BuildPamRequest takes a pointer to a http request and returns a PamRequest with policy values taken from the parameters of the passed request.
BuildPamResponse takes a pointer to a http response and returns a PamResponse with the ComputationLevel taken from the response header.
BuildRequestPolicy takes a http request and extracts the values for a RequestPolicy from its parameters.
ComputationLevelFromString converts a string to the relevant ComputationLevel.
MakePolicyAwareClient returns an PolicyAwareClient with initialised fields.
NewDynamicComputationPolicy returns a pointer to a DynamicComputationPolicy with an empty, initialised internal map.
No description provided by the author
NewStaticComputationPolicy returns a pointer to an initialised StaticComputationPolicy.
NewStaticDataPolicy returns a pointer to a StaticDataPolicy with initialised fields.
NewTableOperations returns a pointer to a TableOperations struct with initialised fields.
PolicyAwareHandler returns a http.Handler based on the passed ComputationPolicy.
ProcessingLocationFromString converts from a string to the relevant ProcessingLocation.

# Constants

No description provided by the author
Specified if the request should ideally be executed locally and never leave the device.
No description provided by the author
No description provided by the author
Specified if the returned data would ideally be unprocessed.

# Structs

DynamicComputationPolicy holds a set of computation capabilities for paths, these must be set manually.
MySQLPrivateDatabase is a wrapper around a MySQL database which implements the PrivateRelationalDatabase interface, it supports DataPolicies which specify transforms for columns and excluded columns on a per PrivacyGroup basis.
PamRequest contains a RequestPolicy and a http request.
PamResponse contains a http response and its associated computation level.
PolicyAwareClient wraps a http client with a ComputationPolicy.
PrivacyGroup a struct which contain a data structure of RequesterID's which we can Add to and Remove from.
RequestPolicy stores the preferred location for processing of a request (and the identity of the requester?).
StaticComputationPolicy holds a map from http request paths to computation capabilities which dictate which handlers can be used for the request.
StaticDataPolicy implements the DataPolicy interface and contains a list of privacyGroups and DataTransforms for them.
TableOperations contains functions to apply to tables before sending to an entity and columns to exclude.

# Interfaces

ComputationPolicy stores the computation capabilities of a node.
DataPolicy allow us to get a function which must be applied to data before returning for a given identifier.
PrivateRelationalDatabase wraps an SQL database and edits queries so that they operate over tables adjusted to match privacy policies.

# Type aliases

No description provided by the author
ComputationLevel specifies whether a handler for a http request can compute no globalResult, just provide the raw data or compute a full globalResult.
transforms is a map from privacyGroups to TableOperations.
ProcessingLocation refers to either local or remote computation over data.
No description provided by the author