Wiki

Imprimir Propiedades
Operators

The response of the server invocation usually is a JSON (JavaScript Object Notation) which is a lightweight computer data interchange format. It is a text-based, human-readable format for representing simple data structures and associative arrays that are called objects. This associative arrays can be manipulated with the operators available.

Basic Operators

New Object

This operator creates a new object, extending from a base object. The base object field is not mandatory and more properties can be also added to the base object clicking on the button “Add New Input”. The “Name” field is the name of the property and the “Value” field is the value of this property.
Panel of the New Object operator

Key/Value Pair List

It creates an array from an object, which contains key/value pair of the object properties.
Panel of the Key/Value Pair List operator

Branch

This operator evaluates the condition given to redirect the flow of the application.

Cast

Force-casting given value to specified type.

Array Operators

This kind of operators makes operations with arrays, the elements of this arrays typically are objects (associative arrays).

New array

This functionality creates a new array extending from a existing one.

Iterate

This operator iterate a array and open a new process for each element of the array, the new process development is similar to a normal process. It collects each element output and emits a new output array.

Filter

This option filters the array elements which the given conditions. To add a new condition, the user has to click in the above button “Add New Condition” and if there is more than one condition, they can be combined with an AND or OR operator (condition mode).
Panel of the filter operator

Join

This operator puts all elements of the array into a string, the elements are separated by given delimiter.
Panel of the join operator

Slice

It gets a selected subset of a given array.
Panel of the slice operator

Concat

This operator joins more than two arrays in one.
Panel of the concat operator

Flatten

This functionality turns multidimensional arrays into linear ones.

Pluck

This operator retrieves the value to the specified property in each element of the given array and returns the results in a new array.
Panel of the pluck operator

Sort By

It allows to sort an array chosen the array to sort, the property name of the objects to compare and the direction of the sort (ascendant or descendent).
Panel of the sort by operator

Unique

Pick unique elements from given array. All duplicate elements are removed, only first one left.
Panel of the unique operator

Group By

This option divides an array into sub array groups. Grouping is based on property value.
Panel of the group by operator

String Operators

Split

This functionality splits the given string into array, cutting the string by the given delimiter
Panel of the split operator

Parse date

This operator parses a date from Unix epoch or W3C-DTF formatted string.
Panel of the parser data operator

RegExp match

It matches entire string with given regular expression.
Panel of the regular expresion operator

Ajax Operators

XMLHttp call

This operator make an Ajax call to an URL given. If the MIME Type of the response is specified and accepted by MyCocktail, the information is ordered in folders and items.
Panel of the XMLHttp call operator

JSONP call

It makes an invocation to a REST service in order to get a JavaScript response which has an invocation to a function with a JSON passed in the parameter of the function. All the services are implemented using this operator. They provides a smarter way to complete the parameters of the RESTful service meanwhile in the JSONP call operator the user has to build the URL with the parameters manually.
Panel of the JSONP operator
1548 Accesos, 0 Ficheros adjuntos 0 Ficheros adjuntos

  • Comentarios