class EdgeAI::Configuration

Overview

methods for viewing and updating the configuration of the device

Defined in:

controllers/configuration.cr

Constant Summary

PARSER_LIST = ["application/json"]

methods for viewing and updating the configuration of the device

PIPELINE_MUTEX = Mutex.new
PIPELINES = begin if File.exists?(PIPELINE_CONFIG) (NamedTuple(pipelines: Hash(String, Pipeline)).from_yaml(File.read(PIPELINE_CONFIG)))[:pipelines] else {} of String => Pipeline end rescue error puts("Error reading #{PIPELINE_CONFIG}: #{error.inspect_with_backtrace}") {} of String => Pipeline end
RESPONDER_LIST = ["application/json", "application/yaml"]

methods for viewing and updating the configuration of the device

Class Method Summary

Instance Method Summary

Instance methods inherited from class EdgeAI::Base

bad_media_type(error) : AC::Error::ContentResponse bad_media_type, invalid_param(error) : AC::Error::ParameterResponse invalid_param, not_found(error) : NamedTuple(error: String | Nil) not_found, set_request_id set_request_id

Class Method Detail

def self.base_route #

Helper for obtaining base route


def self.index(hash_parts : Hash(String | Symbol, Nil | Bool | Int32 | Int64 | Float32 | Float64 | String | Symbol) | Nil = nil, **tuple_parts) #

Helper methods for performing redirect_to calls


Instance Method Detail

def base_route(*args, **options) #

Helper for obtaining base route


def base_route(*args, **options, &) #

Helper for obtaining base route


def clear_all : Array(String) #

clear the current configurations


[View source]
def create(pipeline : Pipeline) : Pipeline #

add a new video pipeline


[View source]
def destroy(id : String) : Nil #

remove a pipeline from the device


[View source]
def index : Array(Pipeline) #

view the current configuration


[View source]
def show(id : String) : Pipeline #

view the current configuration


[View source]
def update(id : String, pipeline : Pipeline) : Pipeline #

replace the configuration with new configuration


[View source]