public override void SetUp() { bool ok = CheckCurrentTargetOK(); if (!ok) { return; } if (credentials == null) { Debug.LogError("Credentials have not been set!"); } DDB_Setup(credentials.region, credentials.cognitoIdentityPool, gameObject.name); var allDataTypes = Enum.GetValues(typeof(UXFDataType)); foreach (UXFDataType dt in allDataTypes) { string tableName = GetTableName(session.experimentName, dt); UXFDataLevel dl = DatabaseDataLevel(dt); string newSortKey = dl == UXFDataLevel.PerTrial ? sortKey : string.Empty; DDB_CreateTable(tableName, primaryKey, newSortKey, gameObject.name); } if (collectBrowserInfo) { AddBrowserInfo(); } }
private UXFDataLevel DatabaseDataLevel(UXFDataType dt) { UXFDataLevel dl = dt.GetDataLevel(); // trial results is a special case, session level file, but trial level data if (dt == UXFDataType.TrialResults) { dl = UXFDataLevel.PerTrial; } return(dl); }
public static IEnumerable <UXFDataType> GetValidDataTypes(this UXFDataLevel level) { return(typeLevelMapping .Where(kvp => kvp.Value == level) .Select(kvp => kvp.Key)); }