// Path: url/src/main/java/com/danisola/restify/url/preconditions/Preconditions.java
// public static void checkArgument(boolean expression, String errorMessage) {
//     if (!expression) {
//         throw new IllegalArgumentException(errorMessage);
//     }
// }


import static com.danisola.restify.url.preconditions.Preconditions.checkArgument;
package com.danisola.restify.url.types;


public class StrVar extends AbstractVarType<String> {

    public static StrVar strVar(String id) {
        return new StrVar(id);
    }

    public static StrVar strVar(String id, String regex) {
        return new StrVar(id, regex);
    }

    private StrVar(String id) {
        super(id);
    }

    private StrVar(String id, String pattern) {
        super(id, pattern);
    }

    @Override
    public String convert(String value) {
// Path: url/src/main/java/com/danisola/restify/url/preconditions/Preconditions.java
// public static void checkArgument(boolean expression, String errorMessage) {
//     if (!expression) {
//         throw new IllegalArgumentException(errorMessage);
//     }
// }


// Path: url/src/main/java/com/danisola/restify/url/types/StrVar.java
import static com.danisola.restify.url.preconditions.Preconditions.checkArgument;

package com.danisola.restify.url.types;


public class StrVar extends AbstractVarType<String> {

    public static StrVar strVar(String id) {
        return new StrVar(id);
    }

    public static StrVar strVar(String id, String regex) {
        return new StrVar(id, regex);
    }

    private StrVar(String id) {
        super(id);
    }

    private StrVar(String id, String pattern) {
        super(id, pattern);
    }

    @Override
    public String convert(String value) {
        checkArgument(value != null, "Argument cannot be null");