51Degrees Device Detection .NET  4.1

Device detection services for 51Degrees Pipeline

FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder Class Reference

Detailed Description

Builder used to create pipelines with an on-premise device detection engine.

Inheritance diagram for FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder:

[legend]

Collaboration diagram for FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder:

[legend]

Public Member Functions

DeviceDetectionOnPremisePipelineBuilder  SetShareUsage (bool enabled)
Set share usage enabled/disabled. More...
DeviceDetectionOnPremisePipelineBuilder  SetAutoUpdate (bool enabled)
Enable/Disable auto update. More...
DeviceDetectionOnPremisePipelineBuilder  SetDataUpdateOnStartUp (bool enabled)
Enable/Disable update on startup. More...
DeviceDetectionOnPremisePipelineBuilder  SetDataUpdateLicenseKey (string key)
Set the license key used when checking for new device detection data files. More...
DeviceDetectionOnPremisePipelineBuilder  SetUpdatePollingInterval (int pollingIntervalSeconds)
Set the time between checks for a new data file made by the FiftyOne.Pipeline.Engines.Services.DataUpdateService. More...
DeviceDetectionOnPremisePipelineBuilder  SetUpdatePollingInterval (TimeSpan pollingInterval)
Set the time between checks for a new data file made by the FiftyOne.Pipeline.Engines.Services.DataUpdateService. More...
DeviceDetectionOnPremisePipelineBuilder  SetUpdateRandomisationMax (int maximumDeviationSeconds)
A random element can be added to the FiftyOne.Pipeline.Engines.Services.DataUpdateService polling interval. More...
DeviceDetectionOnPremisePipelineBuilder  SetUpdateRandomisationMax (TimeSpan maximumDeviation)
A random element can be added to the FiftyOne.Pipeline.Engines.Services.DataUpdateService polling interval. More...
DeviceDetectionOnPremisePipelineBuilder  SetPerformanceProfile (PerformanceProfiles profile)
Set the performance profile for the device detection engine. More...
DeviceDetectionOnPremisePipelineBuilder  SetConcurrency (ushort concurrency)
Set the expected number of concurrent operations using the engine. More...
DeviceDetectionOnPremisePipelineBuilder  SetDifference (int difference)
Set the maximum difference to allow when processing HTTP headers. More...
DeviceDetectionOnPremisePipelineBuilder  SetAllowUnmatched (bool allow)
If set to false, a non-matching User-Agent will result in properties without set values. More...
DeviceDetectionOnPremisePipelineBuilder  SetDataFileSystemWatcher (bool enabled)
The DataUpdateService has the ability to watch a file on disk and refresh the engine as soon as that file is updated. More...
override IPipeline  Build ()
Build and return a pipeline that can perform device detection. More...

Member Function Documentation

◆ Build()

override IPipeline FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.Build ( )

Build and return a pipeline that can perform device detection.

Returns

◆ SetAllowUnmatched()

DeviceDetectionOnPremisePipelineBuilder FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.SetAllowUnmatched ( bool   allow )

If set to false, a non-matching User-Agent will result in properties without set values.

If set to true, a non-matching User-Agent will cause the 'default profiles' to be returned. This means that properties will always have values (i.e. no need to check .HasValue) but some may be inaccurate. By default, this is false.

Parameters
allow - True if results with no matched hash nodes should be considered valid

◆ SetAutoUpdate()

DeviceDetectionOnPremisePipelineBuilder FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.SetAutoUpdate ( bool   enabled )

Enable/Disable auto update.

Defaults to enabled. If enabled, the auto update system will automatically download and apply new data files for device detection.

Parameters
enabled - true to enable auto update. False to disable.
Returns
This builder instance.

◆ SetConcurrency()

DeviceDetectionOnPremisePipelineBuilder FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.SetConcurrency ( ushort   concurrency )

Set the expected number of concurrent operations using the engine.

This sets the concurrency of the internal caches to avoid excessive locking.

Parameters
concurrency - Expected concurrent accesses
Returns
This builder

◆ SetDataFileSystemWatcher()

DeviceDetectionOnPremisePipelineBuilder FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.SetDataFileSystemWatcher ( bool   enabled )

The DataUpdateService has the ability to watch a file on disk and refresh the engine as soon as that file is updated.

This setting enables/disables that feature.

Parameters
enabled - Pass true to enable the feature.
Returns

◆ SetDataUpdateLicenseKey()

DeviceDetectionOnPremisePipelineBuilder FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.SetDataUpdateLicenseKey ( string   key )

Set the license key used when checking for new device detection data files.

Defaults to null.

Parameters
key - The license key
Returns
This builder instance.

◆ SetDataUpdateOnStartUp()

DeviceDetectionOnPremisePipelineBuilder FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.SetDataUpdateOnStartUp ( bool   enabled )

Enable/Disable update on startup.

Defaults to enabled. If enabled, the auto update system will be used to check for an update before the device detection engine is created. If an update is available, it will be downloaded and applied before the pipeline is built and returned for use so this may take some time.

Parameters
enabled - True to enable update on startup. False to disable.
Returns
This builder.

◆ SetDifference()

DeviceDetectionOnPremisePipelineBuilder FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.SetDifference ( int   difference )

Set the maximum difference to allow when processing HTTP headers.

The difference is the difference in hash value between the hash that was found, and the hash that is being searched for. By default this is 0.

Parameters
difference - Difference to allow
Returns
This builder

◆ SetPerformanceProfile()

DeviceDetectionOnPremisePipelineBuilder FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.SetPerformanceProfile ( PerformanceProfiles   profile )

Set the performance profile for the device detection engine.

Defaults to balanced.

Parameters
profile - The performance profile to use.
Returns
This builder instance.

◆ SetShareUsage()

DeviceDetectionOnPremisePipelineBuilder FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.SetShareUsage ( bool   enabled )

Set share usage enabled/disabled.

Defaults to enabled.

Parameters
enabled - true to enable usage sharing. False to disable.
Returns
This builder instance.

◆ SetUpdatePollingInterval() [1/2]

DeviceDetectionOnPremisePipelineBuilder FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.SetUpdatePollingInterval ( int   pollingIntervalSeconds )

Set the time between checks for a new data file made by the FiftyOne.Pipeline.Engines.Services.DataUpdateService.

Default = 30 minutes.

Parameters
pollingIntervalSeconds - The number of seconds between checks.
Returns
This builder instance.

◆ SetUpdatePollingInterval() [2/2]

DeviceDetectionOnPremisePipelineBuilder FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.SetUpdatePollingInterval ( TimeSpan   pollingInterval )

Set the time between checks for a new data file made by the FiftyOne.Pipeline.Engines.Services.DataUpdateService.

Default = 30 minutes.

Parameters
pollingInterval - The time between checks.
Returns
This builder instance.

◆ SetUpdateRandomisationMax() [1/2]

DeviceDetectionOnPremisePipelineBuilder FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.SetUpdateRandomisationMax ( int   maximumDeviationSeconds )

A random element can be added to the FiftyOne.Pipeline.Engines.Services.DataUpdateService polling interval.

This option sets the maximum length of this random addition. Default = 10 minutes.

Parameters
maximumDeviationSeconds - The maximum time added to the data update polling interval.
Returns
This builder instance.

◆ SetUpdateRandomisationMax() [2/2]

DeviceDetectionOnPremisePipelineBuilder FiftyOne.DeviceDetection.DeviceDetectionOnPremisePipelineBuilder.SetUpdateRandomisationMax ( TimeSpan   maximumDeviation )

A random element can be added to the FiftyOne.Pipeline.Engines.Services.DataUpdateService polling interval.

This option sets the maximum length of this random addition. Default = 10 minutes.

Parameters
maximumDeviation - The maximum time added to the data update polling interval.
Returns
This builder instance.