CarpDataEndPoint constructor
CarpDataEndPoint({
- required CarpUploadMethod uploadMethod,
- required String name,
- String? uri,
- String? clientId,
- String? clientSecret,
- String? email,
- String? password,
- String? collection,
- bool deleteWhenUploaded = true,
- String dataFormat = NameSpace.CARP,
- int bufferSize = 500 * 1000,
- bool zip = true,
- bool encrypt = false,
- String? publicKey,
Creates a CarpDataEndPoint.
uploadMethod specified the upload method as enumerated in CarpUploadMethod.
Implementation
CarpDataEndPoint({
required this.uploadMethod,
required this.name,
this.uri,
this.clientId,
this.clientSecret,
this.email,
this.password,
String? collection,
this.deleteWhenUploaded = true,
super.dataFormat,
super.bufferSize,
super.zip,
super.encrypt,
super.publicKey,
}) : super(
type: DataEndPointTypes.CARP,
) {
this.collection = collection ?? DEFAULT_COLLECTION;
// the CARP server cannot handle zipped or encrypted files (yet)
if (this.uploadMethod == CarpUploadMethod.BATCH_DATA_POINT) {
this.zip = false;
this.encrypt = false;
}
}