This is an old revision of the document!


Reject

This Capture layer rejects or hides the current frame if certain conditions are met.

A rejected frame is not stored in the database. A hidden frame is stored, but is marked as 'hidden' so it will not be included in downloads.

Parameters

NameDefaultMeaning
ifOptional - if true, the frame is rejected
requiredOptional - a list of strings. The frame must contain all of these attribute names.
actionignore

Description

This function rejects or hides captures based on conditions.

This is normally used to filter out bad data - for example, unusually short product batches, unavailable data etc.

Example

{
   "type": "reject",
   "required": ["Machine.Speed"],
   "action": "ignore"
}

The layer will not record the capture unless it contains the attribute 'Machine.Speed'.

{
   "type": "reject",
   "if": "{Duration} < 120",
   "action": "hide"
}

The layer will hide the capture if it takes less than 2 minutes.