diff --git a/Cargo.lock b/Cargo.lock index fbb186c..847771c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2276,8 +2276,6 @@ dependencies = [ "futures-lite 2.6.0", "lapin", "log", - "proc-macro2", - "quote", "serde", "serde_json", "tempfile", diff --git a/Cargo.toml b/Cargo.toml index a87ebfc..74b3cd2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -16,10 +16,3 @@ futures-lite = "2.6.0" [dev-dependencies] tempfile = "3.19.1" - -[build-dependencies] -serde = "1.0.219" -serde_json = "1.0.140" -tucana = { version = "0.0.28" } -quote = "1.0" -proc-macro2 = "1.0" diff --git a/build.rs b/build.rs deleted file mode 100644 index 248b222..0000000 --- a/build.rs +++ /dev/null @@ -1,244 +0,0 @@ -use proc_macro2::TokenStream; -use quote::{quote, ToTokens}; -use std::fs::{read_to_string, File}; -use std::io::Write; -use std::process::Command; -use tucana::shared::value::Kind; - -use tucana::shared::{ - DataType, RuntimeFunctionDefinition, RuntimeParameterDefinition, Translation, Value, -}; - -macro_rules! print_on_build { - ($($tokens: tt)*) => { - println!("cargo::warning={}", format!($($tokens)*)) - } -} - -/// Given an actual `Value`, emit the tokens to *reconstruct* it in code. -pub fn value_to_tokens(value: Value) -> TokenStream { - todo!("correct struct imports & strings"); - match &value.kind { - Some(Kind::BoolValue(b)) => { - quote! { - Value { - kind: Some(Kind::BoolValue(#b)) - } - } - } - Some(Kind::NumberValue(n)) => { - quote! { - Value { - kind: Some(Kind::NumberValue(#n)) - } - } - } - Some(Kind::StringValue(s)) => { - quote! { - Value { kind: Some(Kind::StringValue(#s.to_string())) } - } - } - Some(Kind::StructValue(str)) => { - let list_item_tokens: Vec = str - .fields - .iter() - .map(|(k, v)| { - let v_ts = value_to_tokens(v.clone()); - quote! { - (#k.to_string(), #v_ts) - } - }) - .collect(); - - quote! { - Value { - kind: Some(ValueKind::ListValue(Struct { - fields: { - ::std::collections::HashMap::from_iter(vec![ #(#list_item_tokens),* ]) - } - })) - } - } - } - Some(Kind::ListValue(lv)) => { - // embed each item of the real list - let item_tokens: Vec<_> = lv - .values - .iter() - .map(|f| value_to_tokens(f.clone())) - .collect(); - quote! { - Value { - kind: Some(ValueKind::ListValue(vec![ - #(#item_tokens),* - ])) - } - } - } - Some(Kind::NullValue(_)) | None => { - quote! { - Value { kind: Some(ValueKind::NullValue(NullValue::NullValue as i32)) } - } - } - } -} - -fn translation_to_token(translations: Vec) -> Vec { - let mut result: Vec = Vec::new(); - - for trans in translations { - let code = trans.code; - let content = trans.content; - - let token = quote! { - tucana::shared::Translation { - code: String::from(#code), - content: String::from(#content), - } - }; - - result.push(token); - } - result -} - -fn runtime_function_parameter_to_token( - paramter: Vec, -) -> Vec { - let mut result: Vec = Vec::new(); - - for param in paramter { - let runtime_name = param.runtime_name; - let data_type_identifier = param.data_type_identifier; - let default_value = match param.default_value { - Some(value) => value_to_tokens(value), - None => quote! { None }, - }; - let name = translation_to_token(param.name); - let description = translation_to_token(param.description); - let documentation = translation_to_token(param.documentation); - - let quote = quote! { - /* - tucana::shared::RuntimeParameterDefinition { - runtime_name: String::from(#runtime_name), - data_type_identifier: String::from(#data_type_identifier), - default_value: #default_value, - name: vec![#(#name),*], - description: vec![#(#description),*], - documentation: vec![#(#documentation),*] - } - */ - }; - - result.push(quote); - } - result -} - -fn runtime_function_definition_to_token(definition: RuntimeFunctionDefinition) -> TokenStream { - let runtime_name = definition.runtime_name; - let runtime_parameter_definitions = - runtime_function_parameter_to_token(definition.runtime_parameter_definitions); - - // let return_type_identifier = definition.return_type_identifier.into_token_stream(); - - let error_type_identifiers = definition - .error_type_identifiers - .into_iter() - .map(|f| { - quote! { - #f - } - }) - .into_iter() - .collect::>(); - - let name = translation_to_token(definition.name); - let description = translation_to_token(definition.description); - let documentation = translation_to_token(definition.documentation); - let deprecation_message = translation_to_token(definition.deprecation_message); - - quote! { - tucana::shared::RuntimeFunctionDefinition { - runtime_name: String::from(#runtime_name), - runtime_parameter_definitions: vec![#(#runtime_parameter_definitions),*], - // return_type_identifier: Option::Some(String::from(#return_type_identifier)), - error_type_identifiers: vec![#(#error_type_identifiers),*], - name: vec![#(#name),*], - description: vec![#(#description),*], - documentation: vec![#(#documentation),*], - deprecation_message: vec![#(#deprecation_message),*], - } - } -} -fn main() { - // let mut file = File::create("./out/output.rs").expect("msg"); - - let path = "./definitions/runtime_functions/array/array.md"; - let file_content = read_to_string(path).unwrap(); - let mut lines = file_content.split("\n"); - let mut inside_code_block = false; - let mut code_blocks: Vec = Vec::new(); - let mut current_code_block: String = String::from(""); - - while let Some(line) = lines.next() { - if line.contains("```") { - if inside_code_block { - code_blocks.push(current_code_block.clone()); - } else { - current_code_block = String::from("") - } - - inside_code_block = !inside_code_block; - } - - if inside_code_block { - if line.starts_with("```") { - continue; - } - - current_code_block.push_str(line); - } - } - - for code in code_blocks { - match serde_json::from_str::(&code) { - Ok(def) => { - // let quote = runtime_function_definition_to_token(def); - // write!(file, "{},", quote).expect("Cannot write to file"); - } - Err(err) => { - print_on_build!("Error parsing JSON: {:?}", err); - print_on_build!("JSON: {:?}", code); - } - } - } - - /* - write!( - file, - "pub mod output {{ fn getDefinitions() -> Vec {{ vec![" - ) - .expect("Cannot write to file"); - - for res in results { - match res { - Ok(def) => { - let quote = runtime_function_definition_to_token(def); - write!(file, "{},", quote).expect("Cannot write to file"); - } - Err(err) => { - print_on_build!("Error parsing JSON: {}", err); - } - } - } - - write!(file, "] }} }}").expect("Cannot write to file"); - - Command::new("rustfmt") - .arg("./out/output.rs") - .arg("--edition") - .arg("2024"); - */ -} diff --git a/definitions/data_types/array.md b/definitions/data_types/array.md deleted file mode 100644 index 84f2e14..0000000 --- a/definitions/data_types/array.md +++ /dev/null @@ -1,26 +0,0 @@ -# All Data_Types of the Array Variant - -## ARRAY -```json -{ - "variant": 5, - "identifier": "ARRAY", - "name": [ - { - "code": "en-US", - "content": "Generic Array" - } - ], - "rules": [ - { - "contains_type": { - "data_type_identifier": { - "generic_key": "T" - } - } - } - ], - "generic_keys": ["T"], - "parent_type_identifier": null -} -``` diff --git a/definitions/data_types/node.md b/definitions/data_types/node.md deleted file mode 100644 index 5e5d03c..0000000 --- a/definitions/data_types/node.md +++ /dev/null @@ -1,134 +0,0 @@ -## PREDICATE -```json -{ - "identifier": "PREDICATE", - "variant": 7, - "rules": [ - { - "return_type": { - "data_type_identifier": "BOOLEAN" - } - }, - { - "input_type": [ - { - "data_type_identifier": { - "generic_key": "T" - }, - "input_identifier": "predicate" - } - ] - } - ], - "generic_keys": ["T"], - "name": [ - { - "code": "en-US", - "content": "Predicate" - } - ] -} -``` - -## CONSUMER -```json -{ - "identifier": "CONSUMER", - "variant": 7, - "rules": [ - { - "input_type": [ - { - "data_type_identifier": { - "generic_key": "T" - }, - "input_identifier": "consumer" - } - ] - } - ], - "generic_keys": ["T"], - "name": [ - { - "code": "en-US", - "content": "Consumer" - } - ] - -} -``` - -## TRANSFORM -```json -{ - "identifier": "TRANSFORM", - "variant": 7, - "rules": [ - { - "return_type": { - "data_type_identifier": { - "generic_key": "R" - } - } - }, - { - "input_type": [ - { - "data_type_identifier": { - "generic_key": "I" - }, - "input_identifier": "transform" - } - ] - } - ], - "generic_keys": ["I", "R"], - "name": [ - { - "code": "en-US", - "content": "Transform" - } - ] - -} -``` - -## COMPARITOR -```json -{ - "identifier": "COMPARITOR", - "variant": 7, - "rules": [ - { - "return_type": { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - } - } - }, - { - "input_type": [ - { - "data_type_identifier": { - "generic_key": "I" - }, - "input_identifier": "left" - }, - { - "data_type_identifier": { - "generic_key": "I" - }, - "input_identifier": "right" - } - ] - } - ], - "generic_keys": ["I"], - "name": [ - { - "code": "en-US", - "content": "Comparitor" - } - ] -} -``` diff --git a/definitions/data_types/primitive.md b/definitions/data_types/primitive.md deleted file mode 100644 index 5366129..0000000 --- a/definitions/data_types/primitive.md +++ /dev/null @@ -1,71 +0,0 @@ -# All Data_Types of the Primitive Variant - -## NUMBER - -```json -{ - "variant": 1, - "identifier": "NUMBER", - "name": [ - { - "code": "en-US", - "content": "Number" - } - ], - "rules": [ - { - "regex": { - "pattern": "/^(?:-(?:[1-9](?:\d{0,2}(?:,\d{3})+|\d*))|(?:0|(?:[1-9](?:\d{0,2}(?:,\d{3})+|\d*))))(?:.\d+|)$/" - } - } - ], - "generic_keys": [] -} -``` - - -## TEXT - -```json -{ - "variant": 1, - "identifier": "TEXT", - "name": [ - { - "code": "en-US", - "content": "Text" - } - ], - "rules": [ - { - "regex": { - "pattern": "[\s\S]*" - } - } - ], - "generic_keys": [] -} -``` - -## BOOLEAN - -```json -{ - "variant": 1, - "identifier": "BOOLEAN", - "name": [ - { - "code": "en-US", - "content": "Boolean" - } - ], - "rules": [ - { - "regex": { - "pattern": "^(true|false)$" - } - } - ], - "generic_keys": [] -} -``` diff --git a/definitions/data_types/type.md b/definitions/data_types/type.md deleted file mode 100644 index feda618..0000000 --- a/definitions/data_types/type.md +++ /dev/null @@ -1,29 +0,0 @@ -# All Data_Types of the Type Variant - -## NUMBER - -```json -{ - "variant": 2, - "identifier": "TEXT_ENCODING", - "name": [ - { - "code": "en-US", - "content": "Text Encoding" - } - ], - "rules": [ - { - "item_of_collection": { - "items": [ - "ASCII", - "UTF-8", - "UTF-16", - "UTF-32" - ] - } - } - ], - "generic_keys": [] -} -``` diff --git a/definitions/runtime_functions/array/array-audit.md b/definitions/runtime_functions/array/array-audit.md deleted file mode 100644 index 201f448..0000000 --- a/definitions/runtime_functions/array/array-audit.md +++ /dev/null @@ -1,12 +0,0 @@ -# 23.05.2025 - -## Added -- find last - -## Removed -- sortASC -- clear (Doesnt make sense because taurus works with immutable variables) -- replace (Doesnt make sense because taurus works with immutable variables) - -## Renamed: -- sortDEC --> sortReverse diff --git a/definitions/runtime_functions/array/array.md b/definitions/runtime_functions/array/array.md deleted file mode 100644 index ab6fc37..0000000 --- a/definitions/runtime_functions/array/array.md +++ /dev/null @@ -1,2142 +0,0 @@ -## at -Will return the value at the index of the array. - -```json -{ - "runtime_name": "std::array::at", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Input Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array from which to retrieve an element." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "An array containing elements of any type. The element at the specified index will be returned." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "index", - "name": [ - { - "code": "en-US", - "content": "Index" - } - ], - "description": [ - { - "code": "en-US", - "content": "The zero-based index of the element to retrieve." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Specifies the position of the element in the array to return. Must be within the bounds of the array." - } - ] - } - ], - "return_type_identifier": { - "generic_key": "R" - }, - "name": [ - { - "code": "en-US", - "content": "Get Array Element" - } - ], - "description": [ - { - "code": "en-US", - "content": "Retrieves the element at a specified index from an array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the element located at the given zero-based index within the input array." - } - ], - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## concat -Will merge to arrays together and return a new one. -```json -{ - "runtime_name": "std::array::concat", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "first", - "name": [ - { - "code": "en-US", - "content": "First Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The first array to concatenate." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The first input array whose elements will appear at the beginning of the resulting array." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "second", - "name": [ - { - "code": "en-US", - "content": "Second Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The second array to concatenate." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The second input array whose elements will be appended after the elements of the first array." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "name": [ - { - "code": "en-US", - "content": "Concatenate Arrays" - } - ], - "description": [ - { - "code": "en-US", - "content": "Concatenates two arrays into a single array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new array containing all elements of the first array followed by all elements of the second array." - } - ], - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "first", - "source": { - "generic_key": "R" - }, - "target": "T" - }, - { - "parameter_id": "second", - "source": { - "generic_key": "R" - }, - "target": "T" - }, - { - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## filter -Will filter the array by the given node and return all values, the filter node returned true. - -```json -{ - "runtime_name": "std::array::filter", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Input Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array to be filtered." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The original array from which elements will be selected based on the predicate." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "PREDICATE" - }, - "runtime_name": "predicate", - "name": [ - { - "code": "en-US", - "content": "Filter Predicate" - } - ], - "description": [ - { - "code": "en-US", - "content": "A predicate function to test each element for inclusion in the result." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "A function that takes an element of the array and returns a boolean indicating whether the element should be included in the output array." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "name": [ - { - "code": "en-US", - "content": "Filter Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Filters elements of an array based on a predicate." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new array containing only the elements from the input array for which the predicate returns true." - } - ], - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - }, - { - "parameter_id": "predicate", - "source": { - "generic_key": "R" - }, - "target": "T" - }, - { - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## find -Will return the first item of an array that match the predicate. - -```json -{ - "runtime_name": "std::array::find", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Input Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array to search through." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The array in which an element satisfying the predicate will be searched." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "PREDICATE" - }, - "runtime_name": "predicate", - "name": [ - { - "code": "en-US", - "content": "Search Predicate" - } - ], - "description": [ - { - "code": "en-US", - "content": "A predicate function used to test each element for a match." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "A function that takes an element of the array and returns a boolean indicating if the element matches the search criteria." - } - ] - } - ], - "generic_keys": ["R"], - "return_type_identifier": { - "generic_key": "R" - }, - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - }, - { - "parameter_id": "predicate", - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "Find Element in Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Finds the first element in the array that satisfies the predicate." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the first element from the input array for which the predicate returns true. If no element matches, returns null or equivalent." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## findLast -Will return the last item of an array that match the predicate. - -```json -{ - "runtime_name": "std::array::find_last", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Input Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array to search through." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The array in which an element satisfying the predicate will be searched." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "PREDICATE" - }, - "runtime_name": "predicate", - "name": [ - { - "code": "en-US", - "content": "Search Predicate" - } - ], - "description": [ - { - "code": "en-US", - "content": "A predicate function used to test each element for a match." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "A function that takes an element of the array and returns a boolean indicating if the element matches the search criteria." - } - ] - } - ], - "generic_keys": ["R"], - "return_type_identifier": { - "generic_key": "R" - }, - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - }, - { - "parameter_id": "predicate", - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "Find Last Element in Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Finds the last element in the array that satisfies the predicate." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the last element from the input array for which the predicate returns true. If no element matches, returns null or equivalent." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## findIndex -Will return the index of the first item that matches the predicate. - -```json -{ - "runtime_name": "std::array::find_index", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Input Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array to search through." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The array in which to find the index of an element that satisfies the predicate." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "PREDICATE" - }, - "runtime_name": "predicate", - "name": [ - { - "code": "en-US", - "content": "Search Predicate" - } - ], - "description": [ - { - "code": "en-US", - "content": "A predicate function used to test each element for a match." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "A function that takes an element of the array and returns a boolean indicating if the element satisfies the search criteria." - } - ] - } - ], - "generic_keys": ["R"], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - }, - { - "parameter_id": "predicate", - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "Find Index in Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Finds the index of the first element in the array that satisfies the predicate." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the zero-based index of the first element for which the predicate returns true. If no element matches, returns -1." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## first -Will return the first item of the array. - -```json -{ - "runtime_name": "std::array::first", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Input Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array from which to retrieve the first element." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the first element of the provided array. If the array is empty, behavior depends on the implementation." - } - ] - } - ], - "return_type_identifier": { - "generic_key": "R" - }, - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "First Element of Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Retrieves the first element from the array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This runtime returns the first element in the given array, if any." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## last -Will return the last item of the array. - -```json -{ - "runtime_name": "std::array::last", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Input Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array from which to retrieve the last element." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the last element of the provided array. If the array is empty, behavior depends on the implementation." - } - ] - } - ], - "return_type_identifier": { - "generic_key": "R" - }, - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "Last Element of Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Retrieves the last element from the array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This runtime returns the last element in the given array, if any." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## forEach -Will call a consumer on every item in the array. No return value. - -```json -{ - "runtime_name": "std::array::for_each", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Input Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array of elements to iterate over." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Each element of this array will be passed to the provided consumer function for processing." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "CONSUMER" - }, - "runtime_name": "consumer", - "name": [ - { - "code": "en-US", - "content": "Consumer Function" - } - ], - "description": [ - { - "code": "en-US", - "content": "A function that consumes each element of the array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This function is invoked once for each element in the array. It is not expected to return a value." - } - ] - } - ], - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - }, - { - "parameter_id": "consumer", - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "For Each Element" - } - ], - "description": [ - { - "code": "en-US", - "content": "Executes a consumer function for each element in the array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This runtime executes the given consumer function on each item in the array without returning a result." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## map -Will call a node on each value and expect a return value of the node, collect all return values and returns a new array of all collected return values. - -```json -{ - "runtime_name": "std::array::map", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Input Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array to be transformed." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Each element of this array will be passed through the transform function." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TRANSFORM" - }, - "runtime_name": "transform", - "name": [ - { - "code": "en-US", - "content": "Transform Function" - } - ], - "description": [ - { - "code": "en-US", - "content": "A function that transforms each item in the array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The transform function is applied to every element of the array to produce a new array." - } - ] - } - ], - "generic_keys": ["IN", "OUT"], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "IN" - }, - "target": "T" - }, - { - "parameter_id": "transform", - "source": { - "generic_key": "IN" - }, - "target": "I" - }, - { - "parameter_id": "transform", - "source": { - "generic_key": "OUT" - }, - "target": "R" - }, - { - "source": { - "generic_key": "OUT" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "Map Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Transforms each element in the array using the provided function." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This runtime applies the transform function to each element in the array, producing a new array of the results." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## push -Will add the given item to the array and returns the new length of the array. - -```json -{ - "runtime_name": "std::array::push", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array to which an item will be added." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The array that the new item will be appended to." - } - ] - }, - { - "data_type_identifier": { - "generic_key": "I" - }, - "runtime_name": "item", - "name": [ - { - "code": "en-US", - "content": "Item" - } - ], - "description": [ - { - "code": "en-US", - "content": "The item to add to the array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The value to be added at the end of the array." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "generic_keys": ["I"], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "T" - }, - "target": "I" - } - ], - "name": [ - { - "code": "en-US", - "content": "Push to Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Appends an item to the end of an array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Adds a new element to the end of the array and returns the new length of the array." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -[Ref](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/push) - -## pop -Will remove the last entry of the array and return the item. - -```json -{ - "runtime_name": "std::array::pop", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array to remove the last item from." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the array from which the last element will be removed and returned." - } - ] - } - ], - "return_type_identifier": { - "generic_key": "R" - }, - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "Pop from Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Removes and returns the last item from the array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Removes the last element from the specified array and returns it. The array is modified in place." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -[Ref](https://developer.mozilla.org/de/docs/Web/JavaScript/Reference/Global_Objects/Array/pop) - -## remove -Will remove the given item of the array and return the array without it. - -```json -{ - "runtime_name": "std::array::remove", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array from which the item will be removed." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "An array to process by removing the first occurrence of the specified item." - } - ] - }, - { - "data_type_identifier": { - "generic_key": "R" - }, - "runtime_name": "item", - "name": [ - { - "code": "en-US", - "content": "Item" - } - ], - "description": [ - { - "code": "en-US", - "content": "The item to remove from the array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The value to search for and remove from the array. Only the first matching item is removed." - } - ] - } - ], - "generic_keys": ["R"], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "Remove from Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Removes the first occurrence of the specified item from the array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Removes the first matching item from the given array and returns the resulting array." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## isEmpty -Will check if the array is empty or not. Will return true if its empty. - -```json -{ - "runtime_name": "std::array::is_empty", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array to check for emptiness." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The array whose length will be evaluated to determine if it contains any elements." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "Is Array Empty" - } - ], - "description": [ - { - "code": "en-US", - "content": "Checks if the array has no elements." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns true if the array contains no elements, otherwise returns false." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## size -Will return the amount of items inside the array. - -```json -{ - "runtime_name": "std::array::size", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array whose number of elements is to be returned." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Specifies the array for which the total number of elements will be calculated and returned." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "Array Size" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the number of elements in the array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This function returns the count of elements present in the given array." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## indexOf -Will return the index of the given item. - -```json -{ - "runtime_name": "std::array::index_of", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The array to search within." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "An array of elements in which the specified item will be searched for to determine its index." - } - ] - }, - { - "data_type_identifier": { - "generic_key": "R" - }, - "runtime_name": "item", - "name": [ - { - "code": "en-US", - "content": "Item" - } - ], - "description": [ - { - "code": "en-US", - "content": "The item whose index is to be found in the array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The item for which the function searches in the array and returns the index of its first occurrence." - } - ] - } - ], - "generic_keys": ["R"], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "generic_mapper": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "Index of Item" - } - ], - "description": [ - { - "code": "en-US", - "content": "Finds the index of the first occurrence of the specified item in the array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the zero-based index of the first occurrence of a given item in the specified array. If the item is not found, it typically returns -1." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_mappers": [] -} -``` - -## toUnique -Will remove all duplicated items of the array. - -```json -{ - "runtime_name": "std::array::to_unique", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The input array from which duplicates will be removed." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "An array of elements that may contain duplicates. This function will remove any duplicate items and return a new array with unique values only." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - }, - { - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "To Unique" - } - ], - "description": [ - { - "code": "en-US", - "content": "Removes duplicate elements from the input array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new array containing only the unique elements from the input array. The original order may or may not be preserved depending on the implementation." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## sort -Will sort the array by the given COMPARATOR. - -```json -{ - "runtime_name": "std::array::sort", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The input array to be sorted." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "An array of elements that will be sorted using the provided comparator function." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "COMPARATOR" - }, - "runtime_name": "comparator", - "name": [ - { - "code": "en-US", - "content": "Comparator" - } - ], - "description": [ - { - "code": "en-US", - "content": "A comparator function used to determine the sort order of elements." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "A function that takes two elements and returns a negative, zero, or positive number to indicate their ordering." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - }, - { - "parameter_id": "comparator", - "source": { - "generic_key": "R" - }, - "target": "I" - } - ], - "name": [ - { - "code": "en-US", - "content": "Sort Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Sorts the elements of the array using the specified comparator." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new array with the elements sorted according to the comparator function provided." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## sortReverse - -```json -{ - "runtime_name": "std::array::sort_reverse", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The input array to be sorted in reverse order." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "An array of elements that will be sorted in descending order using the provided comparator." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "COMPARATOR" - }, - "runtime_name": "comparator", - "name": [ - { - "code": "en-US", - "content": "Comparator" - } - ], - "description": [ - { - "code": "en-US", - "content": "A comparator function used to determine the sort order of elements." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "A function that takes two elements and returns a negative, zero, or positive number to indicate their ordering." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - }, - { - "parameter_id": "comparator", - "source": { - "generic_key": "R" - }, - "target": "I" - } - ], - "name": [ - { - "code": "en-US", - "content": "Sort Array in Reverse" - } - ], - "description": [ - { - "code": "en-US", - "content": "Sorts the elements of the array in reverse order using the specified comparator." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new array with the elements sorted in descending order according to the comparator function provided." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## reverse - -```json -{ - "runtime_name": "std::array::reverse", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The input array to be reversed." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "An array of elements whose order will be reversed." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "generic_key": "R" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "Reverse Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Reverses the order of elements in the array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new array with the elements of the input array in reverse order." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## flat -Will turn a 2 dimensional array into a one dimensional array. - -Input: -[ [1, 2, 3], [3, 4, 5] ] - -Result: -[ 1, 2, 3, 3, 4, 5 ] - -```json -{ - "runtime_name": "std::array::flat", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Nested Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "The nested array to be flattened." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "An array containing sub-arrays that will be flattened into a single-level array." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "generic_keys": ["R"], - "generic_mappers": [ - { - "parameter_id": "filter", - "target": "R", - "soruce": "T" - }, - { - "parameter_id": "array", - "source": { - "data_type_identifier": "ARRAY" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "Flatten Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Flattens a nested array into a single-level array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new array by concatenating all sub-arrays of the input nested array into one flat array." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## min -Returns the smallest number in the array - -```json -{ - "runtime_name": "std::array::min", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Number Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "An array of numbers to find the minimum value from." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the smallest number in the given array of numbers." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "name": [ - { - "code": "en-US", - "content": "Find Minimum Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "Finds the minimum value in a numeric array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the smallest number contained in the provided array." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "data_type_identifier": "NUMBER" - }, - "target": "T" - } - ] -} -``` - -## max -Returns the largest number in the array - -```json -{ - "runtime_name": "std::array::max", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Number Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "An array of numbers to find the maximum value from." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the largest number in the given array of numbers." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "name": [ - { - "code": "en-US", - "content": "Find Maximum Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "Finds the maximum value in a numeric array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the largest number contained in the provided array." - } - ], - "deprecation_message": [], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "data_type_identifier": "NUMBER" - }, - "target": "T" - } - ], - "generic_keys": [], - "error_type_identifiers": [] -} -``` - - -## sum -Returns the sum of all the numbers in the array - -```json -{ - "runtime_name": "std::array::sum", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Number Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "An array of numbers to be summed." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Calculates the sum of all numbers in the given array." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "name": [ - { - "code": "en-US", - "content": "Sum of Numbers" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the total sum of the elements in the numeric array." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Adds up all numbers in the input array and returns their sum." - } - ], - "deprecation_message": [], - "generic_keys": [], - "error_type_identifiers": [], - "generic_mappers": [ - { - "parameter_id": "array", - "source": { - "data_type_identifier": "NUMBER" - }, - "target": "T" - } - ] -} -``` - -## join -Will join every item by a given text - -```json -{ - "runtime_name": "std::array::join", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "generic_mappers": [ - { - "source": { - "data_type_identifier": "TEXT" - }, - "target": "T" - } - ] - }, - "runtime_name": "array", - "name": [ - { - "code": "en-US", - "content": "Text Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "An array of text elements to be filtered." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Input array containing text elements for filtering." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "join_text", - "name": [ - { - "code": "en-US", - "content": "Join Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "Text to join the filtered elements." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The delimiter or text that will be used to join the filtered array elements into a single string." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "Filter and Join Text Array" - } - ], - "description": [ - { - "code": "en-US", - "content": "Filters the input text array and joins the filtered elements into a single string separated by the specified join text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Applies a filter operation on the input text array and returns a single concatenated string of filtered elements joined by the provided join text." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [], - "error_type_identifiers": [] -} -``` diff --git a/definitions/runtime_functions/object/object-audit.md b/definitions/runtime_functions/object/object-audit.md deleted file mode 100644 index 29ea06e..0000000 --- a/definitions/runtime_functions/object/object-audit.md +++ /dev/null @@ -1,19 +0,0 @@ -# 26.05.2024 - First Iteration - -## Removed: - - concat - - entries - - any - - forEach - - containsValue - - values - - flter - -# 27.05.2024 - -## Removed: - - at - - replace - -## Renamed: - - put -> set diff --git a/definitions/runtime_functions/object/object.md b/definitions/runtime_functions/object/object.md deleted file mode 100644 index 39b793f..0000000 --- a/definitions/runtime_functions/object/object.md +++ /dev/null @@ -1,401 +0,0 @@ -## remove -```json -{ - "runtime_name": "std::object::remove", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "OBJECT" - }, - "runtime_name": "object", - "name": [ - { - "code": "en-US", - "content": "Original Object" - } - ], - "description": [ - { - "code": "en-US", - "content": "The original object from which a key-value pair will be removed." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The object to be modified by removing the specified key." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "key", - "name": [ - { - "code": "en-US", - "content": "Key" - } - ], - "description": [ - { - "code": "en-US", - "content": "The key identifying the property to remove from the object." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The property key that will be removed from the original object." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "OBJECT" - }, - "name": [ - { - "code": "en-US", - "content": "Remove Key from Object" - } - ], - "description": [ - { - "code": "en-US", - "content": "Removes a property identified by the specified key from the given object." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new object that contains all properties from the original object except the one specified by the key." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [], - "error_type_identifiers": [] -} -``` - -## containsKey -```json -{ - "runtime_name": "std::object::contains_key", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "OBJECT" - }, - "runtime_name": "object", - "name": [ - { - "code": "en-US", - "content": "Object" - } - ], - "description": [ - { - "code": "en-US", - "content": "The object to check for the presence of a key." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The object within which the existence of the specified key will be checked." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "key", - "name": [ - { - "code": "en-US", - "content": "Key" - } - ], - "description": [ - { - "code": "en-US", - "content": "The key to check for existence in the object." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The property key whose presence in the object is being tested." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "name": [ - { - "code": "en-US", - "content": "Contains Key" - } - ], - "description": [ - { - "code": "en-US", - "content": "Checks whether the specified key exists in the object." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns true if the given key is a property of the object; otherwise, returns false." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [], - "error_type_identifiers": [] -} -``` - - -## keys -```json -{ - "runtime_name": "std::object::keys", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "OBJECT" - }, - "runtime_name": "object", - "name": [ - { - "code": "en-US", - "content": "Object" - } - ], - "description": [ - { - "code": "en-US", - "content": "The object whose keys will be retrieved." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns an array of all the keys (property names) of the given object." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "generic_keys": ["T"], - "generic_mappers": [ - { - "source": { - "data_type_identifier": "TEXT" - }, - "target": "T" - } - ], - "name": [ - { - "code": "en-US", - "content": "Get Object Keys" - } - ], - "description": [ - { - "code": "en-US", - "content": "Retrieves all the keys from the given object as an array of text values." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns an array containing all enumerable property names (keys) of the specified object." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -## size -```json -{ - "runtime_name": "std::object::size", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "OBJECT" - }, - "runtime_name": "object", - "name": [ - { - "code": "en-US", - "content": "Object" - } - ], - "description": [ - { - "code": "en-US", - "content": "The object whose size (number of keys) will be calculated." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the number of enumerable keys (properties) present in the given object." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "name": [ - { - "code": "en-US", - "content": "Get Object Size" - } - ], - "description": [ - { - "code": "en-US", - "content": "Calculates the number of keys in the provided object." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns an integer count of all enumerable property keys in the specified object." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [], - "error_type_identifiers": [] -} -``` - -## set -```json -{ - "runtime_name": "std::object::set", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "OBJECT" - }, - "runtime_name": "object", - "name": [ - { - "code": "en-US", - "content": "Object" - } - ], - "description": [ - { - "code": "en-US", - "content": "The object in which the key-value pair will be set." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The original object that will be modified with the specified key-value pair." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "key", - "name": [ - { - "code": "en-US", - "content": "Key" - } - ], - "description": [ - { - "code": "en-US", - "content": "The key to set or update in the object." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The property name under which the value will be stored in the object." - } - ] - }, - { - "data_type_identifier": { - "generic_key": "I" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The value to set for the specified key." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The value to assign to the object property identified by the key." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "OBJECT" - }, - "name": [ - { - "code": "en-US", - "content": "Set Object Key" - } - ], - "description": [ - { - "code": "en-US", - "content": "Sets or updates a key-value pair in the given object." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new object with the specified key set to the given value." - } - ], - "generic_keys": ["I"], - "generic_mappers": [ - { - "parameter_id": "value", - "source": { - "generic_key": "I" - }, - "target": "I" - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` diff --git a/definitions/runtime_functions/primitive/boolean-audit.md b/definitions/runtime_functions/primitive/boolean-audit.md deleted file mode 100644 index 8de7a35..0000000 --- a/definitions/runtime_functions/primitive/boolean-audit.md +++ /dev/null @@ -1,13 +0,0 @@ -# 25.04.2025 - First Iteration - -## Added -- asNumber -- asText -- fromText -- fromNumber -- negate - -# 06.05.2025 - -## Added -- isEqual diff --git a/definitions/runtime_functions/primitive/boolean.md b/definitions/runtime_functions/primitive/boolean.md deleted file mode 100644 index 3722197..0000000 --- a/definitions/runtime_functions/primitive/boolean.md +++ /dev/null @@ -1,358 +0,0 @@ -# std for PRIMITIVE: BOOLEAN - -## asNumber -Will convert the boolean to a number. - -```json -{ - "runtime_name": "std::boolean::as_number", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The boolean value to convert." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Converts a boolean value to a number." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "name": [ - { - "code": "en-US", - "content": "As Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "Will convert the boolean to a number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Converts a boolean value to a number." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -false --> 0 - -true --> 1 - -## asText -Will convert the boolean to a string. - -```json -{ - "runtime_name": "std::boolean::as_text", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The boolean value to convert." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Converts a boolean value to a text string." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "As Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "Will convert the boolean to text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Converts a boolean value to a text string." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -false --> "false" - -true --> "true" - - -## fromNumber -Will convert the number to a boolean. - -```json -{ - "runtime_name": "std::boolean::from_number", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to convert." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Converts a number to a boolean value." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "name": [ - { - "code": "en-US", - "content": "From Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "Will convert the number to a boolean." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Converts a number to a boolean value. Typically, 0 maps to false and non-zero maps to true." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -0 --> false - -1 --> true - - -## fromText -Will convert the string to a boolean. - -```json -{ - "runtime_name": "std::boolean::from_text", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text string to convert." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Converts a text string to a boolean value." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "name": [ - { - "code": "en-US", - "content": "From Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "Will convert the string to a boolean." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Converts a text string to a boolean value. Recognizes 'true' and 'false' (case-insensitive)." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"false" --> false - -"true" --> true - - -## isEqual -Will compare one boolean to another. - -```json -{ - "runtime_name": "std::boolean::isEqual", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "runtime_name": "first", - "name": [ - { - "code": "en-US", - "content": "First" - } - ], - "description": [ - { - "code": "en-US", - "content": "The first boolean value to compare." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The first input to compare." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "runtime_name": "second", - "name": [ - { - "code": "en-US", - "content": "Second" - } - ], - "description": [ - { - "code": "en-US", - "content": "The second boolean value to compare." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The second input to compare." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "name": [ - { - "code": "en-US", - "content": "Is Equal" - } - ], - "description": [ - { - "code": "en-US", - "content": "Will check if the two booleans are equal." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Compares two boolean values for equality. Returns true if they are the same, false otherwise." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -false, false --> true - -true, false --> false diff --git a/definitions/runtime_functions/primitive/number-audit.md b/definitions/runtime_functions/primitive/number-audit.md deleted file mode 100644 index 1888f0e..0000000 --- a/definitions/runtime_functions/primitive/number-audit.md +++ /dev/null @@ -1,73 +0,0 @@ -# 25.04.2025 - First Iteration - -## Added - -- add -- multiply -- subtract -- divide -- modulo -- toPositive -- toNegative -- isNegative -- isPositive -- isGreater -- isLess -- isZero -- square -- exponential -- PI -- EULER -- INFINITY -- roundUp -- roundDown -- round -- squareRoot -- root -- log -- naturalLog -- lim -- parseNumber - -# 27.04.2025 - Second Iteration - -## Dropped: -- lim -- toNegative - -## Renamed: -- toPositive -> abs -- naturalLog -> ln - -## Added: - - min - - max - - negate - - randomNumber - - sin - - cos - - tan - - arcsin - - arccos - - arctan - - sinh - - cosh - - clamp - -## Should Consider: -- isGreaterOrEqual -- isLessOrEqual - -# 28.04.2025 - Third Iteration - -## Renamed: -- parseNumber --> fromText - -## Added -- asText - - -# 06.05.2025 - -## Added -- isEqual diff --git a/definitions/runtime_functions/primitive/number.md b/definitions/runtime_functions/primitive/number.md deleted file mode 100644 index c56bf1f..0000000 --- a/definitions/runtime_functions/primitive/number.md +++ /dev/null @@ -1,2875 +0,0 @@ -# std for PRIMITIVE: NUMBER - -## add -Adds two numbers together. - -```json -{ - "runtime_name": "std::number::add", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "first", - "name": [ - { - "code": "en-US", - "content": "First Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The first number to add." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Adds two numbers together." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "second", - "name": [ - { - "code": "en-US", - "content": "Second Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The second number to add." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Adds two numbers together." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "name": [ - { - "code": "en-US", - "content": "Adds two numbers together." - } - ], - "description": [ - { - "code": "en-US", - "content": "Adds two numbers together." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Adds two numbers together." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -3 + 2 --> 5 - -## multiply -Multiplies two numbers together. - -```json -{ - "runtime_name": "std::number::multiply", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "first", - "name": [ - { - "code": "en-US", - "content": "First Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The first number to multiply." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Specifies the first operand in the multiplication operation." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "second", - "name": [ - { - "code": "en-US", - "content": "Second Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The second number to multiply." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Specifies the second operand in the multiplication operation." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Multiply" - } - ], - "description": [ - { - "code": "en-US", - "content": "Multiplies two numbers together." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Takes two numeric inputs and returns their product." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -3 * 2 --> 6 - -## subtract -Subtracts the second number from the first. - -```json -{ - "runtime_name": "std::number::subtract", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "first", - "name": [ - { - "code": "en-US", - "content": "Minuend" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number from which another number (the subtrahend) is to be subtracted." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the number that will have the second value subtracted from it." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "second", - "name": [ - { - "code": "en-US", - "content": "Subtrahend" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to subtract from the first number (the minuend)." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the value that will be subtracted from the first number." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Subtract" - } - ], - "description": [ - { - "code": "en-US", - "content": "Subtracts the second number from the first number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the result of subtracting the second numeric input from the first." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -5 - 2 --> 3 - -## divide -Divides the first number by the second. - -```json -{ - "runtime_name": "std::number::divide", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "first", - "name": [ - { - "code": "en-US", - "content": "Dividend" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to be divided." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the numerator or the number that will be divided by the second value." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "second", - "name": [ - { - "code": "en-US", - "content": "Divisor" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number by which to divide the first number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the denominator or the value that divides the first number." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Divide" - } - ], - "description": [ - { - "code": "en-US", - "content": "Divides the first number by the second number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the result of dividing the first numeric input (dividend) by the second (divisor)." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -6 / 2 --> 3 - -## modulo -Returns the remainder after division of the first number by the second. - -```json -{ - "runtime_name": "std::number::modulo", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "first", - "name": [ - { - "code": "en-US", - "content": "Dividend" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to be divided to find the remainder." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the number that will be divided by the second value to calculate the remainder." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "second", - "name": [ - { - "code": "en-US", - "content": "Divisor" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number by which the first number is divided to get the remainder." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the number used to divide the dividend and obtain the remainder." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Modulo" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the remainder after dividing the first number by the second." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Computes the modulus (remainder) of dividing the first numeric input by the second." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -7 % 3 --> 1 - -## abs -Converts a number to its absolute value. - -```json -{ - "runtime_name": "std::number::abs", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number for which to compute the absolute value." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the numeric input. The result will be its absolute (non-negative) value." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Absolute Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the absolute value of a number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Removes the sign from the input number, returning its non-negative value." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - --5 --> 5 - -## isPositive -Checks if a number is positive. - -```json -{ - "runtime_name": "std::number::is_positive", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to check for positivity." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the numeric input that will be evaluated to determine whether it is greater than zero." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Is Positive" - } - ], - "description": [ - { - "code": "en-US", - "content": "Checks whether a number is greater than zero." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Evaluates the input number and returns true if it is positive (greater than zero), otherwise false." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -5 --> true --2 --> false - -## isGreater -Checks if the first number is greater than the second. - -```json -{ - "runtime_name": "std::number::is_greater", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "first", - "name": [ - { - "code": "en-US", - "content": "First Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to compare against the second number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the number that will be evaluated to determine if it is greater than the second number." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "second", - "name": [ - { - "code": "en-US", - "content": "Second Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to compare with the first number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the number that the first number will be compared to." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Is Greater" - } - ], - "description": [ - { - "code": "en-US", - "content": "Checks whether the first number is greater than the second number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns true if the first numeric input is greater than the second; otherwise, returns false." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -5 > 3 --> true -2 > 4 --> false - -## isLess -Checks if the first number is less than the second. - -```json -{ - "runtime_name": "std::number::is_less", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "first", - "name": [ - { - "code": "en-US", - "content": "First Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to compare with the second number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the number that will be evaluated to determine if it is less than the second number." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "second", - "name": [ - { - "code": "en-US", - "content": "Second Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to compare against the first number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the number that the first number will be compared to." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Is Less" - } - ], - "description": [ - { - "code": "en-US", - "content": "Checks whether the first number is less than the second number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns true if the first numeric input is less than the second; otherwise, returns false." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -3 < 5 --> true -4 < 2 --> false - -## isZero -Checks if a number is zero. - -```json -{ - "runtime_name": "std::number::is_zero", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to check if it is zero." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the numeric input evaluated to determine whether it equals zero." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Is Zero" - } - ], - "description": [ - { - "code": "en-US", - "content": "Checks whether the given number is exactly zero." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns true if the input number is zero; otherwise, returns false." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -0 --> true -5 --> false - -## square -Multiplies a number by itself. - -```json -{ - "runtime_name": "std::number::square", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to be squared." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the numeric input that will be multiplied by itself." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Square" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the square of the given number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Calculates the value multiplied by itself, effectively raising it to the power of 2." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -4 --> 16 - -## exponential -Raises a number to the specified power. - -```json -{ - "runtime_name": "std::number::exponential", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "base", - "name": [ - { - "code": "en-US", - "content": "Base" - } - ], - "description": [ - { - "code": "en-US", - "content": "The base number to be raised to a power." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the numeric value that will be raised to the power of the exponent." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "exponent", - "name": [ - { - "code": "en-US", - "content": "Exponent" - } - ], - "description": [ - { - "code": "en-US", - "content": "The exponent to raise the base number by." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This numeric value indicates the power to which the base is raised." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Exponential" - } - ], - "description": [ - { - "code": "en-US", - "content": "Raises a base number to the power of an exponent." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Computes the result of raising the base to the power specified by the exponent." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -2^3 --> 8 - -## PI -Returns the mathematical constant Pi. - -```json -{ - "runtime_name": "std::number::pi", - "runtime_parameter_definitions": [], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Pi" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the mathematical constant π (pi)." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Provides the constant value of pi, approximately 3.14159, used in many mathematical calculations." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -PI --> 3.14159265359... - -## EULER -Returns the mathematical constant e (Euler's number). - -```json -{ - "runtime_name": "std::number::euler", - "runtime_parameter_definitions": [], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Euler's Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the mathematical constant e (Euler's number)." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Provides the constant value of Euler's number, approximately 2.71828, which is the base of the natural logarithm." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -EULER --> 2.71828182846... - -## INFINITY -Returns the representation of infinity. - -```json -{ - "runtime_name": "std::number::infinity", - "runtime_parameter_definitions": [], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Infinity" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the mathematical concept of positive infinity." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Provides the representation of positive infinity, used to represent an unbounded value in computations." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -INFINITY --> ∞ - -## roundUp -Rounds a number up to the nearest integer. - -```json -{ - "runtime_name": "std::number::round_up", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to be rounded up." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The numeric input that will be rounded upwards." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "decimals", - "name": [ - { - "code": "en-US", - "content": "Decimal Places" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number of decimal places to round up to." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Specifies how many decimal digits to keep after rounding up." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Round Up" - } - ], - "description": [ - { - "code": "en-US", - "content": "Rounds a number upward to the specified number of decimal places." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Performs rounding on the given value, always rounding up to the nearest value at the given decimal precision." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -3.2 (0) --> 4 -3.8 (0) --> 4 -3.008 (3) --> 3.009 -3.008 (1) --> 3.1 - -## roundDown -Rounds a number down to the nearest integer. - -```json -{ - "runtime_name": "std::number::round_down", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to be rounded down." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The numeric input that will be rounded downwards." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "decimals", - "name": [ - { - "code": "en-US", - "content": "Decimal Places" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number of decimal places to round down to." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Specifies how many decimal digits to keep after rounding down." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Round Down" - } - ], - "description": [ - { - "code": "en-US", - "content": "Rounds a number downward to the specified number of decimal places." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Performs rounding on the given value, always rounding down to the nearest value at the given decimal precision." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -3.2 (0) --> 3 -3.8 (0) --> 3 - -3.002 (1) --> 3 -3.778 (2) --> 3.7 - -## round -Rounds a number to the nearest integer. - -```json -{ - "runtime_name": "std::number::round", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to be rounded." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The numeric input that will be rounded to the nearest value." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "decimals", - "name": [ - { - "code": "en-US", - "content": "Decimal Places" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number of decimal places to round to." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Specifies how many decimal digits to keep after rounding." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Round" - } - ], - "description": [ - { - "code": "en-US", - "content": "Rounds a number to the nearest value at the specified number of decimal places." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Performs standard rounding on the given value, rounding up or down depending on the fractional component." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -3.2 (0) --> 3 -3.8 (0) --> 4 - -3.002 (1) --> 3 -3.778 (2) --> 3.78 - -## squareRoot -Calculates the square root of a number. - -```json -{ - "runtime_name": "std::number::square_root", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to find the square root of." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The numeric input for which the square root will be calculated." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Square Root" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the square root of the given number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Calculates the positive square root of the input number." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -16 --> 4 - -## root -Calculates the nth root of a number. - -```json -{ - "runtime_name": "std::number::root", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number from which the root will be extracted." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The numeric input for which the root will be calculated." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "root_exponent", - "name": [ - { - "code": "en-US", - "content": "Root Exponent" - } - ], - "description": [ - { - "code": "en-US", - "content": "The degree of the root to extract." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Specifies which root to calculate (e.g., 2 for square root, 3 for cube root)." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Root" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the root of a number given a root exponent." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Calculates the nth root of the input number, where n is specified by the root exponent." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -27, 3 --> 3 (cube root of 27) - -## log -Calculates the logarithm of a number with the specified base. - -```json -{ - "runtime_name": "std::number::log", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to compute the logarithm for." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The numeric input whose logarithm is to be calculated." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "base", - "name": [ - { - "code": "en-US", - "content": "Base" - } - ], - "description": [ - { - "code": "en-US", - "content": "The base of the logarithm." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Specifies the logarithmic base to use (e.g., 10 for common log, e for natural log)." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Logarithm" - } - ], - "description": [ - { - "code": "en-US", - "content": "Calculates the logarithm of a number with respect to a specified base." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the logarithm of the given value using the specified base." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -100, 10 --> 2 (log base 10 of 100) - -## ln -Calculates the natural logarithm (base e) of a number. - -```json -{ - "runtime_name": "std::number::ln", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to compute the natural logarithm for." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The numeric input whose natural logarithm (log base e) will be calculated." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Natural Logarithm" - } - ], - "description": [ - { - "code": "en-US", - "content": "Calculates the natural logarithm (log base e) of a number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the natural logarithm of the given value." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -2.71828... --> 1 (ln of e) - -## fromText -Converts a string to a number. - -```json -{ - "runtime_name": "std::number::from_text", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "text", - "name": [ - { - "code": "en-US", - "content": "Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text string to convert to a number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Parses the input text and attempts to convert it to a numeric value." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Number from Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "Converts a text string into a number if possible." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Attempts to parse the provided text input and return its numeric equivalent." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"123" --> 123 -"3.14" --> 3.14 - -## asText -Converts a number to a text. - -```json -{ - "runtime_name": "std::number::as_text", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "number", - "name": [ - { - "code": "en-US", - "content": "Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to convert to text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The numeric input that will be converted to its text representation." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Number as Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "Converts a number into its textual representation." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Transforms the given numeric value into a string format." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -123 --> "123" -3.14 --> "3.14" - - -## min -Returns the smaller of two numbers. - -```json -{ - "runtime_name": "std::number::min", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "first", - "name": [ - { - "code": "en-US", - "content": "First Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The first number to compare." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "One of the two numbers for which the minimum value will be determined." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "second", - "name": [ - { - "code": "en-US", - "content": "Second Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The second number to compare." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The other number involved in the minimum value comparison." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Minimum" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the smaller of two numbers." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Compares two numbers and returns the minimum value." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -5, 3 --> 3 --1, 2 --> -1 - -## max -Returns the larger of two numbers. - -```json -{ - "runtime_name": "std::number::max", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "first", - "name": [ - { - "code": "en-US", - "content": "First Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The first number to compare." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "One of the two numbers for which the maximum value will be determined." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "second", - "name": [ - { - "code": "en-US", - "content": "Second Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The second number to compare." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The other number involved in the maximum value comparison." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Maximum" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the larger of two numbers." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Compares two numbers and returns the maximum value." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -5, 3 --> 5 --1, 2 --> 2 - -## negate -Returns the additive inverse of a number. - -```json -{ - "runtime_name": "std::number::negate", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to negate." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The numeric input whose sign will be inverted." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Negate" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the negation of a number (multiplies by -1)." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Calculates the additive inverse of the given number." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -5 --> -5 --3 --> 3 - -## randomNumber -Generates a random number between the specified minimum and maximum values. - -```json -{ - "runtime_name": "std::number::random_number", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "min", - "name": [ - { - "code": "en-US", - "content": "Minimum" - } - ], - "description": [ - { - "code": "en-US", - "content": "The minimum value in the random number range." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Defines the lower bound (inclusive) for the random number generation." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "max", - "name": [ - { - "code": "en-US", - "content": "Maximum" - } - ], - "description": [ - { - "code": "en-US", - "content": "The maximum value in the random number range." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Defines the upper bound (inclusive) for the random number generation." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "name": [ - { - "code": "en-US", - "content": "Random Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "Generates a random number between the specified minimum and maximum values." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a randomly generated number within the given range, inclusive of both minimum and maximum." - } - ], - "error_type_identifiers": [], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -1, 6 --> 3 (random number between 1 and 6, inclusive) - -## sin -Calculates the sine of an angle (in radians). - -```json -{ - "runtime_name": "std::number::random_number", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "min", - "name": [ - { - "code": "en-US", - "content": "Minimum Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The lower bound of the random number range." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Defines the minimum value (inclusive) for the random number generation." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "max", - "name": [ - { - "code": "en-US", - "content": "Maximum Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The upper bound of the random number range." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Defines the maximum value (inclusive) for the random number generation." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Random Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "Generates a random number within the specified range." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a pseudo-random number between the given minimum and maximum values." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -0 --> 0 -1.5708 (π/2) --> 1 - -## cos -Calculates the cosine of an angle (in radians). - -```json -{ - "runtime_name": "std::number::cos", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "radians", - "name": [ - { - "code": "en-US", - "content": "Radians" - } - ], - "description": [ - { - "code": "en-US", - "content": "The angle in radians to compute the cosine of." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Computes the cosine of the given angle in radians." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Cosine" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the cosine of the specified angle in radians." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Calculates the cosine value of the input angle measured in radians." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -0 --> 1 -3.14159 (π) --> -1 - -## tan -Calculates the tangent of an angle (in radians). - -```json -{ - "runtime_name": "std::number::tan", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "radians", - "name": [ - { - "code": "en-US", - "content": "Radians" - } - ], - "description": [ - { - "code": "en-US", - "content": "The angle in radians to compute the tangent of." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Computes the tangent of the given angle in radians." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Tangent" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the tangent of the specified angle in radians." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Calculates the tangent value of the input angle measured in radians." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -0 --> 0 -0.7854 (π/4) --> 1 - -## arcsin -Calculates the inverse sine (in radians). - -```json -{ - "runtime_name": "std::number::arcsin", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number representing the sine value, must be between -1 and 1." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Calculates the arcsine (inverse sine) of the input value." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Arcsine" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the arcsine of a number, in radians." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Computes the angle in radians whose sine is the given number." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -0 --> 0 -1 --> 1.5708 (π/2) - -## arccos -Calculates the inverse cosine (in radians). - -```json -{ - "runtime_name": "std::number::arccos", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number representing the cosine value, must be between -1 and 1." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Calculates the arccosine (inverse cosine) of the input value." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Arccosine" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the arccosine of a number, in radians." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Computes the angle in radians whose cosine is the given number." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -1 --> 0 --1 --> 3.14159 (π) - -## arctan -Calculates the inverse tangent (in radians). - -```json -{ - "runtime_name": "std::number::arctan", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number representing the tangent value." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Calculates the arctangent (inverse tangent) of the input value." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Arctangent" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the arctangent of a number, in radians." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Computes the angle in radians whose tangent is the given number." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -0 --> 0 -1 --> 0.7854 (π/4) - -## sinh -Calculates the hyperbolic sine of a number. - -```json -{ - "runtime_name": "std::number::sinh", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number for which to calculate the hyperbolic sine." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Computes the hyperbolic sine of the given number." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Hyperbolic Sine" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the hyperbolic sine of a number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Calculates the hyperbolic sine (sinh) of the input value." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -0 --> 0 -1 --> 1.1752 - -## cosh -Calculates the hyperbolic cosine of a number. - -```json -{ - "runtime_name": "std::number::cosh", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number for which to calculate the hyperbolic cosine." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Computes the hyperbolic cosine of the given number." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Hyperbolic Cosine" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the hyperbolic cosine of a number." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Calculates the hyperbolic cosine (cosh) of the input value." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -0 --> 1 -1 --> 1.5431 - -## clamp -Constrains a number to be within a specified range. - -```json -{ - "runtime_name": "std::number::clamp", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The number to be clamped within the range." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The input number that will be limited to the specified range." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "min", - "name": [ - { - "code": "en-US", - "content": "Minimum" - } - ], - "description": [ - { - "code": "en-US", - "content": "The lower bound of the clamping range." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The minimum allowed value in the clamping operation." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "max", - "name": [ - { - "code": "en-US", - "content": "Maximum" - } - ], - "description": [ - { - "code": "en-US", - "content": "The upper bound of the clamping range." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The maximum allowed value in the clamping operation." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Clamp" - } - ], - "description": [ - { - "code": "en-US", - "content": "Limits a number to be within a specified range." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the given number clamped between the minimum and maximum bounds." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -10, 0, 5 --> 5 (clamped to max) --3, 0, 5 --> 0 (clamped to min) -3, 0, 5 --> 3 (within range, unchanged) - -## isEqual -Will compare one boolean to another. - -```json -{ - "runtime_name": "std::number::isEqual", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "first", - "name": [ - { - "code": "en-US", - "content": "First Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The first number to compare." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The first operand in the equality check." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "second", - "name": [ - { - "code": "en-US", - "content": "Second Number" - } - ], - "description": [ - { - "code": "en-US", - "content": "The second number to compare." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The second operand in the equality check." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Is Equal" - } - ], - "description": [ - { - "code": "en-US", - "content": "Checks whether two numbers are equal." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns true if the first number is equal to the second number, otherwise false." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -1, 1 --> true - -1, 2 --> false - -# Additions: -- isGreaterOrEqual -- isLessOrEqual diff --git a/definitions/runtime_functions/primitive/text-audit.md b/definitions/runtime_functions/primitive/text-audit.md deleted file mode 100644 index 4fd7575..0000000 --- a/definitions/runtime_functions/primitive/text-audit.md +++ /dev/null @@ -1,44 +0,0 @@ -# 25.04.2025 - First Iteration - -## Added - - - asBytes - - byteSize - - capitalize - - uppercase - - lowercase - - swapcase - - chars - - at - - strip - - concat - - prepend - - insert - - length - - remove - - replace - - replaceFirst - - replaceLast - - hex - - octal - - indexOf - - contains - - split - - reverse - - startWith - - endsWith - - toASCII - - fromASCII - - encode - -# 27.04.2025 - Second Iteration - -## Renamed: - - strip --> trim - - concate --> append - - -# 06.05.2025 - -## Added -- isEqual diff --git a/definitions/runtime_functions/primitive/text.md b/definitions/runtime_functions/primitive/text.md deleted file mode 100644 index 7290f1b..0000000 --- a/definitions/runtime_functions/primitive/text.md +++ /dev/null @@ -1,2422 +0,0 @@ -# std for PRIMITIVE: TEXT - -## asBytes -Converts the text to a number array. - -```json -{ - "runtime_name": "std::text::as_bytes", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text to convert into bytes." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Converts the input text string into an array of byte values." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "generic_mappers": [ - { - "source": { - "data_type_identifier": "NUMBER" - }, - "target": "T" - } - ], - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "As Bytes" - } - ], - "description": [ - { - "code": "en-US", - "content": "Converts a text string into an array of byte values." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns an array of bytes representing the UTF-8 encoding of the given text." - } - ], - "deprecation_message": [], - "generic_keys": [] -} -``` - -**Example**: - -"hello" --> [104, 101, 108, 108, 111] - -## byteSize -Returns the size of the text in bytes. - -```json -{ - "runtime_name": "std::text::byte_size", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text whose byte size is to be calculated." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Calculates the size in bytes of the given text, typically its UTF-8 encoding length." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Byte Size" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the number of bytes required to encode the given text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Computes the size in bytes of the provided text string, typically by counting UTF-8 encoded bytes." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello" --> 5 - -## capitalize -Capitalizes the first character of the text. - -```json -{ - "runtime_name": "std::text::capitalize", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text string to capitalize." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Capitalizes the first letter of the input text string." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Capitalize" - } - ], - "description": [ - { - "code": "en-US", - "content": "Converts the first character of the text to uppercase and leaves the rest unchanged." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new text string with the first letter capitalized." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello" --> "Hello" - -"world wide web" --> "World wide web" - -## uppercase -Converts all characters in the text to uppercase. - -```json -{ - "runtime_name": "std::text::uppercase", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text string to convert to uppercase." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Converts all characters in the input text string to uppercase." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Uppercase" - } - ], - "description": [ - { - "code": "en-US", - "content": "Transforms all letters in the text to their uppercase equivalents." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new text string with all characters converted to uppercase." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello" --> "HELLO" - -"Hello World" --> "HELLO WORLD" - -## lowercase -Converts all characters in the text to lowercase. - -```json -{ - "runtime_name": "std::text::lowercase", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text string to convert to lowercase." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Converts all characters in the input text string to lowercase." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Lowercase" - } - ], - "description": [ - { - "code": "en-US", - "content": "Transforms all letters in the text to their lowercase equivalents." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new text string with all characters converted to lowercase." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"HELLO" --> "hello" - -"Hello World" --> "hello world" - -## swapcase -Swaps the case of all characters in the text. - -```json -{ - "runtime_name": "std::text::swapcase", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text string whose case will be swapped." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Swaps the case of each letter in the input text: uppercase letters become lowercase, and vice versa." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Swap Case" - } - ], - "description": [ - { - "code": "en-US", - "content": "Converts uppercase letters to lowercase and lowercase letters to uppercase in the given text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new text string with the case of each character inverted." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"Hello" --> "hELLO" - -"Hello World" --> "hELLO wORLD" - -## chars -Splits the text into an array of characters. - -```json -{ - "runtime_name": "std::text::chars", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text string to split into characters." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Splits the input text string into an array of its constituent characters." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "generic_keys": ["R"], - "generic_mappers": [ - { - "source": { - "data_type_identifier": "TEXT" - }, - "target": "R" - } - ], - "name": [ - { - "code": "en-US", - "content": "Characters" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns an array containing each character from the given text string." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Creates an array where each element is a single character from the original text." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -**Example**: - -"hello" --> ["h", "e", "l", "l", "o"] - -## at -Returns the character at the specified index. - -```json -{ - "runtime_name": "std::text::at", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text string from which to extract the character." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The input text from which a character will be retrieved by index." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "index", - "name": [ - { - "code": "en-US", - "content": "Index" - } - ], - "description": [ - { - "code": "en-US", - "content": "The zero-based position of the character to extract." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Specifies which character to return from the text." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "error_type_identifiers": [], - "name": [ - { - "code": "en-US", - "content": "Character at Index" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the character at the specified index in the text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Retrieves a single character from the input text based on the provided zero-based index." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello", 1 --> "e" - -"world", 0 --> "w" - -## trim -Removes whitespace from both ends of the text. - -```json -{ - "runtime_name": "std::text::trim", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text Value" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text string to trim whitespace from." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The input text from which leading and trailing whitespace characters will be removed." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "Trim Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "Removes leading and trailing whitespace from the text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new string with all leading and trailing whitespace characters removed from the input text." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -" hello " --> "hello" - -" hello world " --> "hello world" - -## apped -Concatenates two strings together. - -```json -{ - "runtime_name": "std::text::append", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Original Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The initial text to which the suffix will be appended." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The base text string that will have another string appended to its end." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "suffix", - "name": [ - { - "code": "en-US", - "content": "Suffix" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text to append to the original value." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The text string that will be concatenated to the end of the original text." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "Append Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "Concatenates the suffix text to the end of the original text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new text string consisting of the original text followed by the specified suffix." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello", " world" --> "hello world" - -"abc", "123" --> "abc123" - -## prepend -Adds text to the beginning of the string. - -```json -{ - "runtime_name": "std::text::prepend", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Original Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The initial text to which the prefix will be added." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The base text string that will have another string prepended to its beginning." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "prefix", - "name": [ - { - "code": "en-US", - "content": "Prefix" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text to prepend before the original value." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The text string that will be concatenated to the start of the original text." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "Prepend Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "Concatenates the prefix text to the beginning of the original text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new text string consisting of the specified prefix followed by the original text." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"world", "hello " --> "hello world" - -"123", "abc" --> "abc123" - -## insert -Inserts text at the specified position. - -```json -{ - "runtime_name": "std::text::insert", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Original Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The original text into which another text will be inserted." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the base string where the insertion happens." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "position", - "name": [ - { - "code": "en-US", - "content": "Position" - } - ], - "description": [ - { - "code": "en-US", - "content": "The index at which the text will be inserted." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Zero-based index indicating where the new text should be inserted." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "text", - "name": [ - { - "code": "en-US", - "content": "Text to Insert" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text that will be inserted into the original text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The substring to be inserted at the specified position." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "Insert Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "Inserts a given text into the original text at the specified position." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new string where the provided text is inserted at the zero-based position index within the original text." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"helloworld", 5, " " --> "hello world" - -"abcdef", 3, "123" --> "abc123def" - -## length -Returns the length of the text. - -```json -{ - "runtime_name": "std::text::length", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text whose length will be calculated." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Input string to determine the number of characters it contains." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "name": [ - { - "code": "en-US", - "content": "Length" - } - ], - "description": [ - { - "code": "en-US", - "content": "Returns the number of characters in the given text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Computes the length of the input string in terms of characters." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello" --> 5 - -"hello world" --> 11 - -## remove -Removes a portion of text from the specified start index to end index. - -```json -{ - "runtime_name": "std::text::remove", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The original text to remove a substring from." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The input text from which a substring will be removed." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "start", - "name": [ - { - "code": "en-US", - "content": "Start Index" - } - ], - "description": [ - { - "code": "en-US", - "content": "The zero-based index where removal begins." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The starting position for removing characters from the text." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "runtime_name": "end", - "name": [ - { - "code": "en-US", - "content": "End Index" - } - ], - "description": [ - { - "code": "en-US", - "content": "The zero-based index where removal ends (exclusive)." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The position just after the last character to be removed." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "Remove Substring" - } - ], - "description": [ - { - "code": "en-US", - "content": "Removes the substring between the specified start and end indices from the input text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new string with characters removed from start up to but not including end." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello world", 5, 6 --> "helloworld" - -"abcdefg", 2, 5 --> "abfg" - -## replace -Replaces all occurrences of a substring with another string. - -```json -{ - "runtime_name": "std::text::replace", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Original Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The input text where replacements will be made." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This is the text in which all occurrences of the old substring will be replaced." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "old", - "name": [ - { - "code": "en-US", - "content": "Old Substring" - } - ], - "description": [ - { - "code": "en-US", - "content": "The substring to be replaced." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "All occurrences of this substring in the original text will be replaced." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "new", - "name": [ - { - "code": "en-US", - "content": "New Substring" - } - ], - "description": [ - { - "code": "en-US", - "content": "The substring to replace with." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This substring will replace each occurrence of the old substring." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "Replace Substring" - } - ], - "description": [ - { - "code": "en-US", - "content": "Replaces all occurrences of a specified substring with another substring in the input text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new string where every instance of the old substring is replaced by the new substring." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello world", "world", "universe" --> "hello universe" - -"ababab", "a", "c" --> "cbcbcb" - -## replaceFirst -Replaces the first occurrence of a substring with another string. - -```json -{ - "runtime_name": "std::text::replace_first", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Original Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The input text where the first replacement will be made." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This text contains the substring that will be replaced only once—the first occurrence." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "old", - "name": [ - { - "code": "en-US", - "content": "Old Substring" - } - ], - "description": [ - { - "code": "en-US", - "content": "The substring to be replaced." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Only the first occurrence of this substring will be replaced in the original text." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "new", - "name": [ - { - "code": "en-US", - "content": "New Substring" - } - ], - "description": [ - { - "code": "en-US", - "content": "The substring to replace with." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This substring will replace only the first occurrence of the old substring." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "Replace First Substring" - } - ], - "description": [ - { - "code": "en-US", - "content": "Replaces the first occurrence of a specified substring with another substring in the input text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new string where only the first instance of the old substring is replaced by the new substring." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello hello", "hello", "hi" --> "hi hello" - -"ababab", "a", "c" --> "cbabab" - -## replaceLast -Replaces the last occurrence of a substring with another string. - -```json -{ - "runtime_name": "std::text::replace_last", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Original Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The input text where the last replacement will be made." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This text contains the substring that will be replaced only once—the last occurrence." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "old", - "name": [ - { - "code": "en-US", - "content": "Old Substring" - } - ], - "description": [ - { - "code": "en-US", - "content": "The substring to be replaced." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Only the last occurrence of this substring will be replaced in the original text." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "new", - "name": [ - { - "code": "en-US", - "content": "New Substring" - } - ], - "description": [ - { - "code": "en-US", - "content": "The substring to replace with." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This substring will replace only the last occurrence of the old substring." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "Replace Last Substring" - } - ], - "description": [ - { - "code": "en-US", - "content": "Replaces the last occurrence of a specified substring with another substring in the input text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new string where only the last instance of the old substring is replaced by the new substring." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello hello", "hello", "hi" --> "hello hi" - -"ababab", "a", "c" --> "ababcb" - -## hex -Converts the text to a hexadecimal representation. - -```json -{ - "runtime_name": "std::text::hex", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Input Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text string to be converted to its hexadecimal representation." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This function converts each character of the input text into its corresponding hexadecimal code, returning the concatenated hex string." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "Text to Hexadecimal" - } - ], - "description": [ - { - "code": "en-US", - "content": "Converts a text string into a hexadecimal representation." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a string containing the hexadecimal values corresponding to each character of the input text." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello" --> "68656c6c6f" - -"ABC" --> "414243" - -## octal -Converts the text to an octal representation. - -```json -{ - "runtime_name": "std::text::octal", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Input Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text string to be converted to its octal representation." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "This function converts each character of the input text into its corresponding octal code, returning the concatenated octal string." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "Text to Octal" - } - ], - "description": [ - { - "code": "en-US", - "content": "Converts a text string into an octal representation." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a string containing the octal values corresponding to each character of the input text." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello" --> "150145154154157" - -"ABC" --> "101102103" - -## indexOf -Returns the index of the first occurrence of a substring, or -1 if not found. - -```json -{ - "runtime_name": "std::text::index_of", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text string to search within." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The text string to search within." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "substring", - "name": [ - { - "code": "en-US", - "content": "Substring" - } - ], - "description": [ - { - "code": "en-US", - "content": "The substring to find inside the text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The substring to find inside the text." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "NUMBER" - }, - "name": [ - { - "code": "en-US", - "content": "Index Of" - } - ], - "description": [ - { - "code": "en-US", - "content": "Finds the first occurrence index of the substring within the text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns the zero-based index of the first occurrence of the substring in the text. Returns -1 if the substring is not found." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello world", "world" --> 6 - -"hello world", "not found" --> -1 - -## contains -Checks if the text contains a specified substring. - -```json -{ - "runtime_name": "std::text::contains", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The main text to search within." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The main text to search within." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "substring", - "name": [ - { - "code": "en-US", - "content": "Substring" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text to search for inside the main text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The text to search for inside the main text." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "name": [ - { - "code": "en-US", - "content": "Contains" - } - ], - "description": [ - { - "code": "en-US", - "content": "Checks if the main text contains the specified substring." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns true if the substring is found anywhere in the main text; otherwise, returns false." - } - ], - "deprecation_message": [], - "generic_keys": [], - "error_type_identifiers": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello world", "world" --> true - -"hello world", "not found" --> false - -## split -Splits the text into an array of strings based on a delimiter. - -```json -{ - "runtime_name": "std::text::split", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The input text to be split." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The input text to be split." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "delimiter", - "name": [ - { - "code": "en-US", - "content": "Delimiter" - } - ], - "description": [ - { - "code": "en-US", - "content": "The delimiter string to split the text by." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The delimiter string to split the text by." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "generic_keys": ["R"], - "generic_mappers": [ - { - "source": { - "data_type_identifier": "TEXT" - }, - "target": "R" - } - ], - "name": [ - { - "code": "en-US", - "content": "Split" - } - ], - "description": [ - { - "code": "en-US", - "content": "Splits the input text into an array of substrings based on the specified delimiter." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns an array of substrings obtained by splitting the input text at each occurrence of the delimiter." - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -**Example**: - -"hello world", " " --> ["hello", "world"] - -"a,b,c", "," --> ["a", "b", "c"] - -## reverse -Reverses the text. - -```json -{ - "runtime_name": "std::text::reverse", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The input text to be reversed." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The input text to be reversed." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "Reverse" - } - ], - "description": [ - { - "code": "en-US", - "content": "Reverses the characters in the input text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns a new string with the characters of the input text in reverse order." - } - ], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [], - "error_type_identifiers": [] -} -``` - -**Example**: - -"hello" --> "olleh" - -"world" --> "dlrow" - -## startWith -Checks if the text starts with a specified prefix. - -```json -{ - "runtime_name": "std::text::start_with", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The input text to check." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The input text to check." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "prefix", - "name": [ - { - "code": "en-US", - "content": "Prefix" - } - ], - "description": [ - { - "code": "en-US", - "content": "The prefix to test against the input text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The prefix to test against the input text." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "name": [ - { - "code": "en-US", - "content": "Starts With" - } - ], - "description": [ - { - "code": "en-US", - "content": "Checks if the input text starts with the specified prefix." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns true if the input text begins with the given prefix; otherwise, returns false." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello world", "hello" --> true - -"hello world", "world" --> false - -## endsWith -Checks if the text ends with a specified suffix. - -```json -{ - "runtime_name": "std::text::ends_with", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The input text to check." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The input text to check." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "suffix", - "name": [ - { - "code": "en-US", - "content": "Suffix" - } - ], - "description": [ - { - "code": "en-US", - "content": "The suffix to test against the input text." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The suffix to test against the input text." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "name": [ - { - "code": "en-US", - "content": "Ends With" - } - ], - "description": [ - { - "code": "en-US", - "content": "Checks if the input text ends with the specified suffix." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns true if the input text ends with the given suffix; otherwise, returns false." - } - ], - "deprecation_message": [], - "error_type_identifiers": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"hello world", "world" --> true - -"hello world", "hello" --> false - -## toASCII -Converts each character to its ASCII code as an array of numbers. - -```json -{ - "runtime_name": "std::text::to_ascii", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "Input text to convert to ASCII codes." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Input text to convert to ASCII codes." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "name": [ - { - "code": "en-US", - "content": "To ASCII" - } - ], - "description": [ - { - "code": "en-US", - "content": "Converts each character of the input text into its corresponding ASCII numerical code." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Returns an array of numbers where each number represents the ASCII code of the corresponding character in the input text." - } - ], - "generic_keys": ["R"], - "generic_mappers": [ - { - "source": { - "data_type_identifier": "NUMBER" - }, - "target": "R" - } - ], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -**Example**: - -"hello" --> [104, 101, 108, 108, 111] - -"ABC" --> [65, 66, 67] - -## fromASCII -Converts an array of ASCII codes to a text string. - -```json -{ - "runtime_name": "std::text::from_ascii", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "ARRAY" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "ASCII Codes" - } - ], - "description": [ - { - "code": "en-US", - "content": "Array of ASCII numeric codes representing characters." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Array of ASCII numeric codes representing characters." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "From ASCII" - } - ], - "description": [ - { - "code": "en-US", - "content": "Converts an array of ASCII codes back into the corresponding text string." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Takes an array of numbers where each number is an ASCII code, and returns the string they represent." - } - ], - "generic_mappers": [ - { - "parameter_id": "value", - "source": { - "data_type_identifier": "NUMBER" - }, - "target": "T" - } - ], - "generic_keys": [], - "deprecation_message": [], - "error_type_identifiers": [] -} -``` - -**Example**: - -[104, 101, 108, 108, 111] --> "hello" - -[65, 66, 67] --> "ABC" - -## encode -Encodes the text using a specified encoding. - -```json -{ - "runtime_name": "std::text::encode", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "value", - "name": [ - { - "code": "en-US", - "content": "Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The text string to encode." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The text string to encode." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT_ENCODING" - }, - "runtime_name": "encoding", - "name": [ - { - "code": "en-US", - "content": "Encoding Type" - } - ], - "description": [ - { - "code": "en-US", - "content": "The encoding scheme to apply (e.g., UTF-8, Base64)." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The encoding scheme to apply (e.g., UTF-8, Base64)." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "TEXT" - }, - "name": [ - { - "code": "en-US", - "content": "Encode Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "Encodes the input text into the specified encoding format." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Transforms the given text string into a representation encoded by the specified encoding scheme." - } - ], - "generic_keys": [], - "generic_mappers": [], - "error_type_identifiers": [], - "deprecation_message": [] -} -``` - -**Example**: - -"hello", "base64" --> "aGVsbG8=" - -## isEqual - -```json -{ - "runtime_name": "std::text::is_equal", - "runtime_parameter_definitions": [ - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "first", - "name": [ - { - "code": "en-US", - "content": "First Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The first text string to compare." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The first input text for equality comparison." - } - ] - }, - { - "data_type_identifier": { - "data_type_identifier": "TEXT" - }, - "runtime_name": "second", - "name": [ - { - "code": "en-US", - "content": "Second Text" - } - ], - "description": [ - { - "code": "en-US", - "content": "The second text string to compare." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "The second input text for equality comparison." - } - ] - } - ], - "return_type_identifier": { - "data_type_identifier": "BOOLEAN" - }, - "name": [ - { - "code": "en-US", - "content": "Is Equal" - } - ], - "description": [ - { - "code": "en-US", - "content": "Checks whether the two input text strings are equal." - } - ], - "documentation": [ - { - "code": "en-US", - "content": "Determines if the two given text inputs are exactly the same, returning true if equal, false otherwise." - } - ], - "error_type_identifiers": [], - "deprecation_message": [], - "generic_keys": [], - "generic_mappers": [] -} -``` - -**Example**: - -"TEXT", "TEXT" --> true - -"TEXT", "WORD" --> false