aboutsummaryrefslogtreecommitdiffstats
path: root/config/src/main/java/com/yahoo/vespa/config/protocol/CompressionType.java
blob: 82f6c78c997ec237210450f29e34a7f1ca5ac12d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.vespa.config.protocol;

/**
 * @author Ulf Lilleengen
 */
public enum CompressionType {
    UNCOMPRESSED, LZ4;
    public static CompressionType parse(String value) {
        for (CompressionType type : CompressionType.values()) {
            if (type.name().equals(value)) {
                return type;
            }
        }
        return CompressionType.UNCOMPRESSED;
    }
}