Skip to content

Commit

Permalink
[docs] .and() clause (#2143)
Browse files Browse the repository at this point in the history
* [docs] `.and() clause`

* [docs] update per review.
  • Loading branch information
jamesnocentini authored and pasin committed Apr 18, 2018
1 parent 7671ee3 commit b98ba90
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions Swift/Expression.swift
Original file line number Diff line number Diff line change
Expand Up @@ -313,6 +313,10 @@ public final class Expression {

/// Creates a negated expression representing the negated result of the given expression.
///
/// If the operand isn't a boolean type, it gets coerced to a boolean. The number 0 is coerced to false,
/// the number 1 is coerced to `true`, strings are coerced to `false` (but strings prefixed with a number
/// are coerced to `true`, for example "[email protected]").
///
/// - Parameter expression: The expression to be negated.
/// - Returns: A negated expression
public static func not(_ expression: ExpressionProtocol) -> ExpressionProtocol {
Expand Down Expand Up @@ -486,6 +490,10 @@ public final class Expression {
/// Creates a logical AND expression that performs logical AND operation with the current
/// expression.
///
/// If the operand isn't a boolean type, it gets coerced to a boolean. The number 0 is coerced to false,
/// the number 1 is coerced to `true`, strings are coerced to `false` (but strings prefixed with a number
/// are coerced to `true`, for example "[email protected]").
///
/// - Parameter expression: The expression to AND with the current expression.
/// - Returns: A logical AND expression.
public func and(_ expression: ExpressionProtocol) -> ExpressionProtocol {
Expand All @@ -495,6 +503,10 @@ public final class Expression {
/// Creates a logical OR expression that performs logical OR operation with the current
/// expression.
///
/// If the operand isn't a boolean type, it gets coerced to a boolean. The number 0 is coerced to false,
/// the number 1 is coerced to `true`, strings are coerced to `false` (but strings prefixed with a number
/// are coerced to `true`, for example "[email protected]").
///
/// - Parameter expression: The expression to OR with the current expression.
/// - Returns: A logical OR Expression.
public func or(_ expression: ExpressionProtocol) -> ExpressionProtocol {
Expand Down

0 comments on commit b98ba90

Please sign in to comment.