All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.openapiprocessor.jsonschema.converter.BooleanConverter Maven / Gradle / Ivy

/*
 * Copyright 2021 https://github.com/openapi-processor/openapi-parser
 * PDX-License-Identifier: Apache-2.0
 */

package io.openapiprocessor.jsonschema.converter;

import org.checkerframework.checker.nullness.qual.Nullable;

import static io.openapiprocessor.jsonschema.support.Types.convertOrNull;

/**
 * converts the property {@code value} to {@link Boolean}.
 */
public class BooleanConverter implements PropertyConverter {

    @Override
    public @Nullable Boolean convert (String name, @Nullable Object value, String location) {
        return convertOrNull (location, value, Boolean.class);
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy