Tuya iOS Smart Life App SDK 5.15.0
ThingSmartScenePreConditionFactory Class Reference

ThingSmartScenePreConditionFactory provides convenient construction methods for developers to generate precondition object. More...

#import <ThingSmartScenePreConditionFactory.h>

Inheritance diagram for ThingSmartScenePreConditionFactory:

Class Methods

(ThingSmartScenePreConditionModel *) + creatAllDayPreConditionWithSceneId:existConditionId:loops:timeZoneId:
 
(ThingSmartScenePreConditionModel *) + createDayTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:
 
(ThingSmartScenePreConditionModel *) + createNightTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:
 
(ThingSmartScenePreConditionModel *) + createCustomTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:beginTime:endTime:
 
(ThingSmartScenePreConditionModel *) + scenePreconditionWithParam:
 
(ThingSmartScenePreConditionModel *) + creatAllDayPreConditionWithSceneId:existConditionId:loops:timeZoneId:
 
(ThingSmartScenePreConditionModel *) + createDayTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:
 
(ThingSmartScenePreConditionModel *) + createNightTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:
 
(ThingSmartScenePreConditionModel *) + createCustomTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:beginTime:endTime:
 
(ThingSmartScenePreConditionModel *) + scenePreconditionWithParam:
 
(ThingSmartScenePreConditionModel *) + creatAllDayPreConditionWithSceneId:existConditionId:loops:timeZoneId:
 
(ThingSmartScenePreConditionModel *) + createDayTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:
 
(ThingSmartScenePreConditionModel *) + createNightTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:
 
(ThingSmartScenePreConditionModel *) + createCustomTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:beginTime:endTime:
 
(ThingSmartScenePreConditionModel *) + scenePreconditionWithParam:
 
(ThingSmartScenePreConditionModel *) + creatAllDayPreConditionWithSceneId:existConditionId:loops:timeZoneId:
 
(ThingSmartScenePreConditionModel *) + createDayTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:
 
(ThingSmartScenePreConditionModel *) + createNightTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:
 
(ThingSmartScenePreConditionModel *) + createCustomTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:beginTime:endTime:
 
(ThingSmartScenePreConditionModel *) + scenePreconditionWithParam:
 

Detailed Description

ThingSmartScenePreConditionFactory provides convenient construction methods for developers to generate precondition object.

Definition at line 16 of file ThingSmartScenePreConditionFactory.h.

Method Documentation

◆ creatAllDayPreConditionWithSceneId:existConditionId:loops:timeZoneId: [1/4]

+ (ThingSmartScenePreConditionModel *) creatAllDayPreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
timeZoneId: (NSString *)  timeZoneId 

Create an all-day valid precondition.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
Returns
The ThingSmartScenePreConditionModel instance.

◆ creatAllDayPreConditionWithSceneId:existConditionId:loops:timeZoneId: [2/4]

+ (ThingSmartScenePreConditionModel *) creatAllDayPreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
timeZoneId: (NSString *)  timeZoneId 

Create an all-day valid precondition.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
Returns
The ThingSmartScenePreConditionModel instance.

◆ creatAllDayPreConditionWithSceneId:existConditionId:loops:timeZoneId: [3/4]

+ (ThingSmartScenePreConditionModel *) creatAllDayPreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
timeZoneId: (NSString *)  timeZoneId 

Create an all-day valid precondition.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
Returns
The ThingSmartScenePreConditionModel instance.

◆ creatAllDayPreConditionWithSceneId:existConditionId:loops:timeZoneId: [4/4]

+ (ThingSmartScenePreConditionModel *) creatAllDayPreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
timeZoneId: (NSString *)  timeZoneId 

Create an all-day valid precondition.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
Returns
The ThingSmartScenePreConditionModel instance.

◆ createCustomTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:beginTime:endTime: [1/4]

+ (ThingSmartScenePreConditionModel *) createCustomTimePreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
cityId: (NSString *)  cityId
cityName: (NSString *)  cityName
timeZoneId: (NSString *)  timeZoneId
beginTime: (NSString *)  begin
endTime: (NSString *)  end 

Create a valid precondition of custom time period.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
cityIdThe current city id.
cityNameThe current city name.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
beginThe begin date. eg:"00:59".
endThe end date. eg:"18:30".
Returns
The ThingSmartScenePreConditionModel instance.

◆ createCustomTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:beginTime:endTime: [2/4]

+ (ThingSmartScenePreConditionModel *) createCustomTimePreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
cityId: (NSString *)  cityId
cityName: (NSString *)  cityName
timeZoneId: (NSString *)  timeZoneId
beginTime: (NSString *)  begin
endTime: (NSString *)  end 

Create a valid precondition of custom time period.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
cityIdThe current city id.
cityNameThe current city name.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
beginThe begin date. eg:"00:59".
endThe end date. eg:"18:30".
Returns
The ThingSmartScenePreConditionModel instance.

◆ createCustomTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:beginTime:endTime: [3/4]

+ (ThingSmartScenePreConditionModel *) createCustomTimePreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
cityId: (NSString *)  cityId
cityName: (NSString *)  cityName
timeZoneId: (NSString *)  timeZoneId
beginTime: (NSString *)  begin
endTime: (NSString *)  end 

Create a valid precondition of custom time period.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
cityIdThe current city id.
cityNameThe current city name.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
beginThe begin date. eg:"00:59".
endThe end date. eg:"18:30".
Returns
The ThingSmartScenePreConditionModel instance.

◆ createCustomTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId:beginTime:endTime: [4/4]

+ (ThingSmartScenePreConditionModel *) createCustomTimePreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
cityId: (NSString *)  cityId
cityName: (NSString *)  cityName
timeZoneId: (NSString *)  timeZoneId
beginTime: (NSString *)  begin
endTime: (NSString *)  end 

Create a valid precondition of custom time period.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
cityIdThe current city id.
cityNameThe current city name.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
beginThe begin date. eg:"00:59".
endThe end date. eg:"18:30".
Returns
The ThingSmartScenePreConditionModel instance.

◆ createDayTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId: [1/4]

+ (ThingSmartScenePreConditionModel *) createDayTimePreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
cityId: (NSString *)  cityId
cityName: (NSString *)  cityName
timeZoneId: (NSString *)  timeZoneId 

Create a daytime valid precondition.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
cityIdThe current city id.
cityNameThe current city name.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
Returns
The ThingSmartScenePreConditionModel instance.

◆ createDayTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId: [2/4]

+ (ThingSmartScenePreConditionModel *) createDayTimePreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
cityId: (NSString *)  cityId
cityName: (NSString *)  cityName
timeZoneId: (NSString *)  timeZoneId 

Create a daytime valid precondition.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
cityIdThe current city id.
cityNameThe current city name.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
Returns
The ThingSmartScenePreConditionModel instance.

◆ createDayTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId: [3/4]

+ (ThingSmartScenePreConditionModel *) createDayTimePreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
cityId: (NSString *)  cityId
cityName: (NSString *)  cityName
timeZoneId: (NSString *)  timeZoneId 

Create a daytime valid precondition.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
cityIdThe current city id.
cityNameThe current city name.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
Returns
The ThingSmartScenePreConditionModel instance.

◆ createDayTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId: [4/4]

+ (ThingSmartScenePreConditionModel *) createDayTimePreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
cityId: (NSString *)  cityId
cityName: (NSString *)  cityName
timeZoneId: (NSString *)  timeZoneId 

Create a daytime valid precondition.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
cityIdThe current city id.
cityNameThe current city name.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
Returns
The ThingSmartScenePreConditionModel instance.

◆ createNightTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId: [1/4]

+ (ThingSmartScenePreConditionModel *) createNightTimePreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
cityId: (NSString *)  cityId
cityName: (NSString *)  cityName
timeZoneId: (NSString *)  timeZoneId 

Create a night valid precondition.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
cityIdThe current city id.
cityNameThe current city name.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
Returns
The ThingSmartScenePreConditionModel instance.

◆ createNightTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId: [2/4]

+ (ThingSmartScenePreConditionModel *) createNightTimePreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
cityId: (NSString *)  cityId
cityName: (NSString *)  cityName
timeZoneId: (NSString *)  timeZoneId 

Create a night valid precondition.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
cityIdThe current city id.
cityNameThe current city name.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
Returns
The ThingSmartScenePreConditionModel instance.

◆ createNightTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId: [3/4]

+ (ThingSmartScenePreConditionModel *) createNightTimePreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
cityId: (NSString *)  cityId
cityName: (NSString *)  cityName
timeZoneId: (NSString *)  timeZoneId 

Create a night valid precondition.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
cityIdThe current city id.
cityNameThe current city name.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
Returns
The ThingSmartScenePreConditionModel instance.

◆ createNightTimePreConditionWithSceneId:existConditionId:loops:cityId:cityName:timeZoneId: [4/4]

+ (ThingSmartScenePreConditionModel *) createNightTimePreConditionWithSceneId: (nullable NSString *)  sceneId
existConditionId: (nullable NSString *)  conditionId
loops: (NSString *)  loops
cityId: (NSString *)  cityId
cityName: (NSString *)  cityName
timeZoneId: (NSString *)  timeZoneId 

Create a night valid precondition.

Parameters
sceneIdThe scene id. You can pass nil when create an automation scene.
conditionIdThe current condition id. You need to pass the original condition id when editing scene for automation scene.
loopsThe loop description, the data format is "1111111". Each bit indicates the Sunday to Saturday, 1 means valid, 0 means invalid.
cityIdThe current city id.
cityNameThe current city name.
timeZoneIdThe timezone id, eg:"Asia/Shanghai".
Returns
The ThingSmartScenePreConditionModel instance.

◆ scenePreconditionWithParam: [1/4]

+ (ThingSmartScenePreConditionModel *) scenePreconditionWithParam: (TSmartScenePreconditionParam *)  preconditionParam

Create a precondition model for scene.

Parameters
preconditionParamThe parameters for precondition, detail see TSmartScenePreconditionParam.

@retuen The ThingSmartScenePreConditionModel object.

◆ scenePreconditionWithParam: [2/4]

+ (ThingSmartScenePreConditionModel *) scenePreconditionWithParam: (TSmartScenePreconditionParam *)  preconditionParam

Create a precondition model for scene.

Parameters
preconditionParamThe parameters for precondition, detail see TSmartScenePreconditionParam.

@retuen The ThingSmartScenePreConditionModel object.

◆ scenePreconditionWithParam: [3/4]

+ (ThingSmartScenePreConditionModel *) scenePreconditionWithParam: (TSmartScenePreconditionParam *)  preconditionParam

Create a precondition model for scene.

Parameters
preconditionParamThe parameters for precondition, detail see TSmartScenePreconditionParam.

@retuen The ThingSmartScenePreConditionModel object.

◆ scenePreconditionWithParam: [4/4]

+ (ThingSmartScenePreConditionModel *) scenePreconditionWithParam: (TSmartScenePreconditionParam *)  preconditionParam

Create a precondition model for scene.

Parameters
preconditionParamThe parameters for precondition, detail see TSmartScenePreconditionParam.

@retuen The ThingSmartScenePreConditionModel object.


The documentation for this class was generated from the following files: