New-FsrmFmjCondition

New-FsrmFmjCondition

Creates a file management property condition object.

Sintaxis

Parameter Set: CreateFmjCondition0
New-FsrmFmjCondition [-Property] <String> [-Condition] <FmjConditionTypeEnum> [-AsJob] [-CimSession <CimSession[]> ] [-DateOffset <Int32> ] [-ThrottleLimit <Int32> ] [-Value <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]

Descripción detallada

The New-FsrmFmjCondition cmdlet creates a file management condition object. A file management condition object defines a condition that determines if a file management job acts on a file.

Parámetros

-AsJob

Alias

ninguno

¿Requerido?

false

¿Posición?

named

Valor predeterminado

ninguno

¿Aceptar canalización?

false

¿Aceptar caracteres comodín?

false

-CimSession<CimSession[]>

Ejecuta el cmdlet en una sesión remota o en un equipo remoto. Escriba un nombre de equipo o un objeto de sesión, como la salida de un cmdlet New-CimSession o Get-CimSession. El valor predeterminado es la sesión actual en el equipo local.

Alias

Session

¿Requerido?

false

¿Posición?

named

Valor predeterminado

ninguno

¿Aceptar canalización?

false

¿Aceptar caracteres comodín?

false

-Condition<FmjConditionTypeEnum>

Specifies the condition of the property that must be matched for the file management job. Los valores aceptables para este parámetro son los siguientes:
-- Equal
-- NotEqual
-- GreaterThan
-- LessThan
-- Contain
-- Exist
-- NotExist
-- StartWith
-- EndWith
-- ContainedIn
-- PrefixOf
-- SuffixOf
-- MatchesPattern

Alias

ninguno

¿Requerido?

true

¿Posición?

3

Valor predeterminado

ninguno

¿Aceptar canalización?

True (ByPropertyName)

¿Aceptar caracteres comodín?

false

-DateOffset<Int32>

Specifies an offset from the Value parameter for DateTime values. The default value is 0.

Alias

ninguno

¿Requerido?

false

¿Posición?

named

Valor predeterminado

ninguno

¿Aceptar canalización?

True (ByPropertyName)

¿Aceptar caracteres comodín?

false

-Property<String>

Specifies the property to compare for the condition. Specify one of the following values:
-- The name of a classification property definition on the server. (Do not specify the display name of the property definition.)
-- The string File.Name
-- The string File.DateCreated
-- The string File.DateLastModified
-- The string File.DateLastAccessed

The value of this parameter limits the values that other parameters to the cmdlet can accept as follows:

File.Name:
-- You can set the Condition parameter only to MatchesPattern.
-- The Value parameter must contain a semi-colon separated list of wildcard patterns.
-- You cannot specify the DateOffset parameter.

File.DateCreated, File.DateLastModified, or File.DateLastAccessed:
-- You can set the Condition parameter only to LessThan or Equal.
-- If you specify the DateOffset parameter, you can set the Value parameter to one of the following: File.DateCreated, File.DateLastModified, File.DateLastAccessed, or Date.Now.
-- If you do not specify the DateOffset parameter, you can set the Value parameter to a FileTime value.

The name of a classification property definition whose Type is DateTime:
-- You can set the Condition parameter to Exist, NotExist, Equal, NotEqual, LessThan, GreaterThan.
-- If you specify the DateOffset parameter, the Value parameter can contain one of the following: File.DateCreated, File.DateLastModified, File.DateLastAccessed, or Date.Now.
-- If you do not specify the DateOffset parameter, the Value parameter can contain a FileTime value.

The name of a classification property definition whose Type is not DateTime:
-- You cannot specify the DateOffset parameter.
-- If the Condition parameter is Exist or NotExist, you cannot specify the Value parameter.
-- If the Type is Integer, you can set the Condition parameter to Equal, NotEqual, Exist, NotExist, LessThan, GreaterThan.
-- If the Type is String, you can set the Condition parameter to Equal, NotEqual, Exist, NotExist, Contains, IsContainedIn, LessThan, GreaterThan, StartsWith, EndsWith, PrefixOf, SuffixOf.
-- If the Type is YesNo, you can set the Condition parameter to Equal, NotEqual, Exist, NotExist.
-- If the Type is OrderedList, you can set the Condition parameter to Equal, NotEqual, Exist, NotExist, LessThan, GreaterThan.
-- If the Type is SingleChoice, you can set the Condition parameter to Equal, NotEqual, Exist, NotExist.
-- If the Type is MultiChoice, you can set the Condition parameter to Equal, NotEqual, Exist, NotExist, Contains.
-- If the Type is MultiString, you can set the Condition parameter to Equal, NotEqual, Exist, NotExist, Contains.

Alias

ninguno

¿Requerido?

true

¿Posición?

2

Valor predeterminado

ninguno

¿Aceptar canalización?

True (ByPropertyName)

¿Aceptar caracteres comodín?

false

-ThrottleLimit<Int32>

Especifica el número máximo de operaciones simultáneas que se pueden establecer para ejecutar el cmdlet. Si se omite este parámetro o es especifica un valor de 0, Windows PowerShell ® calcula un límite óptimo para el cmdlet en función del número de cmdlets de CIM que se estén ejecutando en el equipo. El límite solo se aplica al cmdlet actual, no a la sesión ni al equipo.

Alias

ninguno

¿Requerido?

false

¿Posición?

named

Valor predeterminado

ninguno

¿Aceptar canalización?

false

¿Aceptar caracteres comodín?

false

-Value<String>

Specifies a name of a file condition property value. Do not specify this parameter if you specify Exists or NotExist for the Condition parameter. If you specify the name of a DateTime property, specify the DateOffset parameter.

Alias

ninguno

¿Requerido?

false

¿Posición?

named

Valor predeterminado

ninguno

¿Aceptar canalización?

True (ByPropertyName)

¿Aceptar caracteres comodín?

false

-Confirm

Solicita confirmación antes de ejecutar el cmdlet.

¿Requerido?

false

¿Posición?

named

Valor predeterminado

falso

¿Aceptar canalización?

false

¿Aceptar caracteres comodín?

false

-WhatIf

Muestra lo que sucedería si se ejecutara el cmdlet. El cmdlet no se ejecuta.

¿Requerido?

false

¿Posición?

named

Valor predeterminado

falso

¿Aceptar canalización?

false

¿Aceptar caracteres comodín?

false

<CommonParameters>

Este cmdlet admite los siguientes parámetros comunes: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer y -OutVariable. Para obtener más información, consulte about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).

Entradas

El tipo de entrada es el tipo de los objetos que se pueden canalizar al cmdlet.

Salidas

El tipo de resultado es el tipo de objetos que emite el cmdlet.

Ejemplos

Example 1: Create a property condition

This command creates a property condition that verifies that a file has a PII classification property set to true.

PS C:\> New-FsrmFmjCondition -Property "PII" -Condition Equal -Value "1"

Example 2: Create a condition based on a file classification

This command creates a condition based on the file’s classification. The command verifies that a file has a DatePublished classification property (of type DateTime) set to the file’s Last Modified timestamp.

PS C:\> New-FsrmFmjCondition -Property "DatePublished" -Condition Equal -Value "File.DateLastModified"

Temas relacionados

Get-FsrmClassificationPropertyDefinition