Skip to content

Commit 1a21833

Browse files
committed
Move Fix conditionals to individual classes.
Continuing the refactoring.
1 parent 061dfa5 commit 1a21833

27 files changed

+1050
-66
lines changed

README.md

Lines changed: 27 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1240,31 +1240,31 @@ Executes the functions if/unless the field contains the value. If it is an array
12401240
12411241
[Example in Playground](https://metafacture.org/playground/?example=all_contain)
12421242
1243-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+all_contain+{")
1243+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/AllContain.java)
12441244
12451245
##### `any_contain`
12461246
12471247
Executes the functions if/unless the field contains the value. If it is an array or a hash one or more field values must contain the string.
12481248
12491249
[Example in Playground](https://metafacture.org/playground/?example=any_contain)
12501250
1251-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+any_contain+{")
1251+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/AnyContain.java)
12521252
12531253
##### `none_contain`
12541254
12551255
Executes the functions if/unless the field does not contain the value. If it is an array or a hash none of the field values may contain the string.
12561256
12571257
[Example in Playground](https://metafacture.org/playground/?example=none_contain)
12581258
1259-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+none_contain+{")
1259+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/NoneContain.java)
12601260
12611261
##### `str_contain`
12621262
12631263
Executes the functions if/unless the first string contains the second string.
12641264
12651265
[Example in Playground](https://metafacture.org/playground/?example=str_contain)
12661266
1267-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+str_contain+{")
1267+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/StrContain.java)
12681268
12691269
#### `equal`
12701270
@@ -1274,31 +1274,31 @@ Executes the functions if/unless the field value equals the string. If it is an
12741274
12751275
[Example in Playground](https://metafacture.org/playground/?example=all_equal)
12761276
1277-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+all_equal+{")
1277+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/AllEqual.java)
12781278
12791279
##### `any_equal`
12801280
12811281
Executes the functions if/unless the field value equals the string. If it is an array or a hash one or more field values must equal the string.
12821282
12831283
[Example in Playground](https://metafacture.org/playground/?example=any_equal)
12841284
1285-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+any_equal+{")
1285+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/AnyEqual.java)
12861286
12871287
##### `none_equal`
12881288
12891289
Executes the functions if/unless the field value does not equal the string. If it is an array or a hash none of the field values may equal the string.
12901290
12911291
[Example in Playground](https://metafacture.org/playground/?example=none_equal)
12921292
1293-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+none_equal+{")
1293+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/NoneEqual.java)
12941294
12951295
##### `str_equal`
12961296
12971297
Executes the functions if/unless the first string equals the second string.
12981298
12991299
[Example in Playground](https://metafacture.org/playground/?example=str_equal)
13001300
1301-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+str_equal+{")
1301+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/StrEqual.java)
13021302
13031303
#### `exists`
13041304
@@ -1310,15 +1310,15 @@ if exists("<sourceField>")
13101310
13111311
[Example in Playground](https://metafacture.org/playground/?example=exists)
13121312
1313-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+exists+{")
1313+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/Exists.java)
13141314
13151315
#### `greater_than`
13161316
13171317
Executes the functions if/unless the field value is greater than the given value.
13181318
13191319
[Example in Playground](https://metafacture.org/playground/?example=greater_than)
13201320
1321-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+greater_than+{")
1321+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/GreaterThan.java)
13221322
13231323
#### `in`
13241324
@@ -1328,81 +1328,85 @@ _Also aliased as [`is_contained_in`](#is_contained_in)._
13281328
13291329
[Example in Playground](https://metafacture.org/playground/?example=in)
13301330
1331-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+in+{")
1331+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/In.java)
13321332
13331333
#### `is_contained_in`
13341334
13351335
_Alias for [`in`](#in)._
13361336
1337+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/IsContainedIn.java)
1338+
13371339
#### `is_array`
13381340
13391341
Executes the functions if/unless the field value is an array.
13401342
13411343
[Example in Playground](https://metafacture.org/playground/?example=is_array)
13421344
1343-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+is_array+{")
1345+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/IsArray.java)
13441346
13451347
#### `is_empty`
13461348
13471349
Executes the functions if/unless the field value is empty.
13481350
13491351
[Example in Playground](https://metafacture.org/playground/?example=is_empty)
13501352
1351-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+is_empty+{")
1353+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/IsEmpty.java)
13521354
13531355
#### `is_false`
13541356
13551357
Executes the functions if/unless the field value equals `false` or `0`.
13561358
13571359
[Example in Playground](https://metafacture.org/playground/?example=is_false)
13581360
1359-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+is_false+{")
1361+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/IsFalse.java)
13601362
13611363
#### `is_hash`
13621364
13631365
_Alias for [`is_object`](#is_object)._
13641366
13651367
[Example in Playground](https://metafacture.org/playground/?example=is_hash)
13661368
1367-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+is_hash+{")
1369+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/IsHash.java)
13681370
13691371
#### `is_number`
13701372
13711373
Executes the functions if/unless the field value is a number.
13721374
13731375
[Example in Playground](https://metafacture.org/playground/?example=is_number)
13741376
1375-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+is_number+{")
1377+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/IsNumber.java)
13761378
13771379
#### `is_object`
13781380
13791381
Executes the functions if/unless the field value is a hash (object).
13801382
13811383
_Also aliased as [`is_hash`](#is_hash)._
13821384
1385+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/IsObject.java)
1386+
13831387
#### `is_string`
13841388
13851389
Executes the functions if/unless the field value is a string (and not a number).
13861390
13871391
[Example in Playground](https://metafacture.org/playground/?example=is_string)
13881392
1389-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+is_string+{")
1393+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/IsString.java)
13901394
13911395
#### `is_true`
13921396
13931397
Executes the functions if/unless the field value equals `true` or `1`.
13941398
13951399
[Example in Playground](https://metafacture.org/playground/?example=is_true)
13961400
1397-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+is_true+{")
1401+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/IsTrue.java)
13981402
13991403
#### `less_than`
14001404
14011405
Executes the functions if/unless the field value is less than the given value.
14021406
14031407
[Example in Playground](https://metafacture.org/playground/?example=less_than)
14041408
1405-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+less_than+{")
1409+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/LessThan.java)
14061410
14071411
#### `match`
14081412
@@ -1412,31 +1416,31 @@ Executes the functions if/unless the field value matches the regular expression
14121416
14131417
[Example in Playground](https://metafacture.org/playground/?example=all_match)
14141418
1415-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+all_match+{")
1419+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/AllMatch.java)
14161420
14171421
##### `any_match`
14181422
14191423
Executes the functions if/unless the field value matches the regular expression pattern. If it is an array or a hash one or more field values must match the regular expression pattern.
14201424
14211425
[Example in Playground](https://metafacture.org/playground/?example=any_match)
14221426
1423-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+any_match+{")
1427+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/AnyMatch.java)
14241428
14251429
##### `none_match`
14261430
14271431
Executes the functions if/unless the field value does not match the regular expression pattern. If it is an array or a hash none of the field values may match the regular expression pattern.
14281432
14291433
[Example in Playground](https://metafacture.org/playground/?example=none_match)
14301434
1431-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+none_match+{")
1435+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/NoneMatch.java)
14321436
14331437
##### `str_match`
14341438
14351439
Executes the functions if/unless the string matches the regular expression pattern.
14361440
14371441
[Example in Playground](https://metafacture.org/playground/?example=str_match)
14381442
1439-
[Java Code](https://github.com/search?type=code&q=repo:metafacture/metafacture-core+path:FixConditional.java+"+str_match+{")
1443+
[Java Code](https://github.com/metafacture/metafacture-core/blob/master/metafix/src/main/java/org/metafacture/metafix/conditional/StrMatch.java)
14401444
14411445
## Xtext
14421446

0 commit comments

Comments
 (0)