Documentation
¶
Index ¶
- type AdminRepository
- type AssetRepository
- func (this *AssetRepository) Create(asset *sm.Asset) error
- func (this *AssetRepository) DeleteAssetsForJob(job_id int64) error
- func (this *AssetRepository) GetAsset(asset_id int64) (*sm.Asset, error)
- func (this *AssetRepository) GetAssetByUrlParam(url_param string) (*sm.Asset, error)
- func (this *AssetRepository) GetAssetsForJob(job_id int64, assets *[]*sm.Asset) error
- func (this *AssetRepository) GetAssetsForUser(content_owner_id int64, assets *[]*sm.Asset) error
- type ContentOwnerRepository
- func (this *ContentOwnerRepository) EmailExists(email string) (bool, error)
- func (this *ContentOwnerRepository) GetAll() ([]*sm.ContentOwner, error)
- func (this *ContentOwnerRepository) GetContentOwnerByID(owner *sm.ContentOwner) error
- func (this *ContentOwnerRepository) GetContentOwnerByUsername(username string) (*sm.ContentOwner, error)
- func (this *ContentOwnerRepository) Insert(owner *sm.ContentOwner) error
- func (this *ContentOwnerRepository) NameExists(name string) (bool, error)
- func (this *ContentOwnerRepository) Save(owner *sm.ContentOwner) error
- func (this *ContentOwnerRepository) SavePassword(owner *sm.ContentOwner) error
- func (this *ContentOwnerRepository) UsernameExists(username string) (bool, error)
- type DatabasePool
- type JobRepository
- func (this *JobRepository) CancelJobsWithExceedingExpirationDate(timestamp time.Time) error
- func (this *JobRepository) CancelJobsWithExceedingPublicatinDate(timestamp time.Time) error
- func (this *JobRepository) CreateJob(job *sm.Job) error
- func (this *JobRepository) DeleteParamsForJob(job_id int64) error
- func (this *JobRepository) ExpireJobsBefore(timestamp time.Time) error
- func (this *JobRepository) GetJobByID(job_id int64) (*sm.Job, error)
- func (this *JobRepository) GetJobByStepID(step_id int64) (*sm.Job, error)
- func (this *JobRepository) GetJobStepForModule(step_id, module_id int64) (map[string]interface{}, error)
- func (this *JobRepository) GetJobSteps(job_id int64, steps *[]*sm.JobStep) error
- func (this *JobRepository) GetJobsExceedingExpirationDate(timestamp time.Time, limit, offset_id int64) ([]*sm.Job, error)
- func (this *JobRepository) GetJobsExceedingPublicationDate(timestamp time.Time, limit, offset_id int64) ([]*sm.Job, error)
- func (this *JobRepository) GetJobsForContentOwner(owner_id, limit, before_job_id int64) ([]*sm.Job, error)
- func (this *JobRepository) GetJobsStepsForModule(module_id, limit, before_step_id int64) ([]map[string]interface{}, error)
- func (this *JobRepository) GetNewExpiredJobsAt(timestamp time.Time, limit int64, offset_id int64) ([]*sm.Job, error)
- func (this *JobRepository) GetParamsForStep(step *sm.JobStep) error
- func (this *JobRepository) SaveFinishedState(job *sm.Job) error
- func (this *JobRepository) SaveStatus(job *sm.Job) error
- func (this *JobRepository) SaveStepProgress(job *sm.Job) error
- func (this *JobRepository) TaskHasActiveJobs(task_id int64) (bool, error)
- type ModuleRepository
- func (this *ModuleRepository) CreateModule(module *sm.Module) error
- func (this *ModuleRepository) GenerateApiKey(module_name string) string
- func (this *ModuleRepository) GetModuleByID(id int64) (*sm.Module, error)
- func (this *ModuleRepository) GetModuleByKey(api_key string) (*sm.Module, error)
- func (this *ModuleRepository) GetModules(modules *[]map[string]interface{}) error
- func (this *ModuleRepository) GetModulesOBJ(modules *[]*sm.Module) error
- func (this *ModuleRepository) IsNameInUse(name string) (bool, error)
- func (this *ModuleRepository) Save(module *sm.Module) error
- func (this *ModuleRepository) SetAvailability(id int64, enabled bool) error
- type TaskRepository
- func (this *TaskRepository) CreateTask(task *sm.Task) error
- func (this *TaskRepository) DeleteTask(id int64) error
- func (this *TaskRepository) GetTask(id int64) (*sm.Task, error)
- func (this *TaskRepository) GetTasks(module_id int64, fetch_deleted bool) ([]*sm.Task, error)
- func (this *TaskRepository) NameExists(name string) (bool, error)
- func (this *TaskRepository) Save(task *sm.Task) error
- func (this *TaskRepository) SaveVars(task *sm.Task, is_input bool) error
- func (this *TaskRepository) SetAvailability(id int64, enabled bool) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdminRepository ¶
type AdminRepository struct {
Pool *DatabasePool
}
func (*AdminRepository) GetByID ¶
func (this *AdminRepository) GetByID(id int64) (*sm.AdminUser, error)
func (*AdminRepository) GetByUsername ¶
func (this *AdminRepository) GetByUsername(username string) (*sm.AdminUser, error)
func (*AdminRepository) SavePassword ¶
func (this *AdminRepository) SavePassword(admin *sm.AdminUser) error
type AssetRepository ¶
type AssetRepository struct {
Pool *DatabasePool
}
func (*AssetRepository) DeleteAssetsForJob ¶
func (this *AssetRepository) DeleteAssetsForJob(job_id int64) error
func (*AssetRepository) GetAsset ¶
func (this *AssetRepository) GetAsset(asset_id int64) (*sm.Asset, error)
func (*AssetRepository) GetAssetByUrlParam ¶
func (this *AssetRepository) GetAssetByUrlParam(url_param string) (*sm.Asset, error)
func (*AssetRepository) GetAssetsForJob ¶
func (this *AssetRepository) GetAssetsForJob(job_id int64, assets *[]*sm.Asset) error
func (*AssetRepository) GetAssetsForUser ¶
func (this *AssetRepository) GetAssetsForUser(content_owner_id int64, assets *[]*sm.Asset) error
type ContentOwnerRepository ¶
type ContentOwnerRepository struct {
Pool *DatabasePool
}
func (*ContentOwnerRepository) EmailExists ¶
func (this *ContentOwnerRepository) EmailExists(email string) (bool, error)
func (*ContentOwnerRepository) GetAll ¶
func (this *ContentOwnerRepository) GetAll() ([]*sm.ContentOwner, error)
func (*ContentOwnerRepository) GetContentOwnerByID ¶
func (this *ContentOwnerRepository) GetContentOwnerByID(owner *sm.ContentOwner) error
func (*ContentOwnerRepository) GetContentOwnerByUsername ¶
func (this *ContentOwnerRepository) GetContentOwnerByUsername( username string) (*sm.ContentOwner, error)
func (*ContentOwnerRepository) Insert ¶
func (this *ContentOwnerRepository) Insert(owner *sm.ContentOwner) error
func (*ContentOwnerRepository) NameExists ¶
func (this *ContentOwnerRepository) NameExists(name string) (bool, error)
func (*ContentOwnerRepository) Save ¶
func (this *ContentOwnerRepository) Save(owner *sm.ContentOwner) error
func (*ContentOwnerRepository) SavePassword ¶
func (this *ContentOwnerRepository) SavePassword(owner *sm.ContentOwner) error
func (*ContentOwnerRepository) UsernameExists ¶
func (this *ContentOwnerRepository) UsernameExists(username string) (bool, error)
type DatabasePool ¶
func Open ¶
func Open() (*DatabasePool, error)
func (*DatabasePool) Close ¶
func (this *DatabasePool) Close()
type JobRepository ¶
type JobRepository struct {
Pool *DatabasePool
}
func (*JobRepository) CancelJobsWithExceedingExpirationDate ¶
func (this *JobRepository) CancelJobsWithExceedingExpirationDate( timestamp time.Time) error
func (*JobRepository) CancelJobsWithExceedingPublicatinDate ¶
func (this *JobRepository) CancelJobsWithExceedingPublicatinDate( timestamp time.Time) error
func (*JobRepository) DeleteParamsForJob ¶
func (this *JobRepository) DeleteParamsForJob(job_id int64) error
func (*JobRepository) ExpireJobsBefore ¶
func (this *JobRepository) ExpireJobsBefore(timestamp time.Time) error
func (*JobRepository) GetJobByID ¶
func (this *JobRepository) GetJobByID(job_id int64) (*sm.Job, error)
func (*JobRepository) GetJobByStepID ¶
func (this *JobRepository) GetJobByStepID(step_id int64) (*sm.Job, error)
func (*JobRepository) GetJobStepForModule ¶
func (this *JobRepository) GetJobStepForModule( step_id, module_id int64) (map[string]interface{}, error)
func (*JobRepository) GetJobSteps ¶
func (this *JobRepository) GetJobSteps(job_id int64, steps *[]*sm.JobStep) error
func (*JobRepository) GetJobsExceedingExpirationDate ¶
func (*JobRepository) GetJobsExceedingPublicationDate ¶
func (*JobRepository) GetJobsForContentOwner ¶
func (this *JobRepository) GetJobsForContentOwner( owner_id, limit, before_job_id int64) ([]*sm.Job, error)
func (*JobRepository) GetJobsStepsForModule ¶
func (this *JobRepository) GetJobsStepsForModule( module_id, limit, before_step_id int64) ([]map[string]interface{}, error)
func (*JobRepository) GetNewExpiredJobsAt ¶
func (*JobRepository) GetParamsForStep ¶
func (this *JobRepository) GetParamsForStep(step *sm.JobStep) error
func (*JobRepository) SaveFinishedState ¶
func (this *JobRepository) SaveFinishedState(job *sm.Job) error
SaveFinishedState saves the completion_date, status and sets the is_completed to true
func (*JobRepository) SaveStatus ¶
func (this *JobRepository) SaveStatus(job *sm.Job) error
func (*JobRepository) SaveStepProgress ¶
func (this *JobRepository) SaveStepProgress(job *sm.Job) error
SaveStepProgress updates the current_step and also saves the output of the previous task to the database
func (*JobRepository) TaskHasActiveJobs ¶
func (this *JobRepository) TaskHasActiveJobs(task_id int64) (bool, error)
type ModuleRepository ¶
type ModuleRepository struct {
Pool *DatabasePool
}
func (*ModuleRepository) CreateModule ¶
func (this *ModuleRepository) CreateModule(module *sm.Module) error
func (*ModuleRepository) GenerateApiKey ¶
func (this *ModuleRepository) GenerateApiKey(module_name string) string
func (*ModuleRepository) GetModuleByID ¶
func (this *ModuleRepository) GetModuleByID(id int64) (*sm.Module, error)
func (*ModuleRepository) GetModuleByKey ¶
func (this *ModuleRepository) GetModuleByKey(api_key string) (*sm.Module, error)
func (*ModuleRepository) GetModules ¶
func (this *ModuleRepository) GetModules(modules *[]map[string]interface{}) error
func (*ModuleRepository) GetModulesOBJ ¶
func (this *ModuleRepository) GetModulesOBJ(modules *[]*sm.Module) error
func (*ModuleRepository) IsNameInUse ¶
func (this *ModuleRepository) IsNameInUse(name string) (bool, error)
func (*ModuleRepository) SetAvailability ¶
func (this *ModuleRepository) SetAvailability(id int64, enabled bool) error
type TaskRepository ¶
type TaskRepository struct {
Pool *DatabasePool
}
func (*TaskRepository) CreateTask ¶
func (this *TaskRepository) CreateTask(task *sm.Task) error
func (*TaskRepository) DeleteTask ¶
func (this *TaskRepository) DeleteTask(id int64) error
func (*TaskRepository) NameExists ¶
func (this *TaskRepository) NameExists(name string) (bool, error)
func (*TaskRepository) SaveVars ¶
func (this *TaskRepository) SaveVars(task *sm.Task, is_input bool) error
func (*TaskRepository) SetAvailability ¶
func (this *TaskRepository) SetAvailability(id int64, enabled bool) error
Click to show internal directories.
Click to hide internal directories.