SessionProgram.Builder#
from tmlt.analytics import SessionProgram
- class SessionProgram.Builder#
Automatically generated builder for initializing a
SessionProgram
.A subclass of this class is automatically generated for each subclass of
SessionProgram
. It has a similar interface toSession.Builder
.- build()#
Returns an instance of the matching
SessionProgram
subtype.- Return type:
- with_id_space(id_space)#
Adds an identifier space.
This defines a space of identifiers that map 1-to-1 to the identifiers being protected by a table with the
AddRowsWithID
protected change. Any table with such a protected change must be a member of some identifier space.
- with_privacy_budget(privacy_budget)#
Set the privacy budget for the object being built.
- with_private_dataframe(source_id, dataframe, protected_change)#
Adds a Spark DataFrame as a private source.
Not all Spark column types are supported in private sources; see
ColumnType
for information about which types are supported.- Parameters:
source_id (
str
) – Source id for the private source dataframe.dataframe (
DataFrame
) – Private source dataframe to perform queries on, corresponding to thesource_id
.protected_change (
ProtectedChange
) – AProtectedChange
specifying what changes to the input data should be protected.
- Return type: