<commit_before>/**
 * Copyright (c) 2015 Bosch Software Innovations GmbH and others.
 *
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 */
package org.eclipse.hawkbit.ddi.json.model;

import java.util.Collections;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonValue;

/**
 * Detailed update action information.
 */
public class DdiDeployment {

    private HandlingType download;

    private HandlingType update;

    private List<DdiChunk> chunks;

    /**
     * Constructor.
     */
    public DdiDeployment() {
        // needed for json create.
    }

    /**
     * Constructor.
     *
     * @param download
     *            handling type
     * @param update
     *            handling type
     * @param chunks
     *            to handle.
     */
    public DdiDeployment(final HandlingType download, final HandlingType update, final List<DdiChunk> chunks) {
        this.download = download;
        this.update = update;
        this.chunks = chunks;
    }

    public HandlingType getDownload() {
        return download;
    }

    public HandlingType getUpdate() {
        return update;
    }

    public List<DdiChunk> getChunks() {
        if (chunks == null) {
            return Collections.emptyList();
        }
        
        return Collections.unmodifiableList(chunks);
    }

    /**
     * Handling type for the update action.
     */
    public enum HandlingType {

        /**
         * Try to execute (local applications may intervene by SP control API).
         */
        ATTEMPT("attempt"),<commit_msg>Readd enum constant "skip" (#574)<commit_after>/**
 * Copyright (c) 2015 Bosch Software Innovations GmbH and others.
 *
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 */
package org.eclipse.hawkbit.ddi.json.model;

import java.util.Collections;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonValue;

/**
 * Detailed update action information.
 */
public class DdiDeployment {

    private HandlingType download;

    private HandlingType update;

    private List<DdiChunk> chunks;

    /**
     * Constructor.
     */
    public DdiDeployment() {
        // needed for json create.
    }

    /**
     * Constructor.
     *
     * @param download
     *            handling type
     * @param update
     *            handling type
     * @param chunks
     *            to handle.
     */
    public DdiDeployment(final HandlingType download, final HandlingType update, final List<DdiChunk> chunks) {
        this.download = download;
        this.update = update;
        this.chunks = chunks;
    }

    public HandlingType getDownload() {
        return download;
    }

    public HandlingType getUpdate() {
        return update;
    }

    public List<DdiChunk> getChunks() {
        if (chunks == null) {
            return Collections.emptyList();
        }
        
        return Collections.unmodifiableList(chunks);
    }

    /**
     * The handling type for the update action.
     */
    public enum HandlingType {

        /**
         * Not necessary for the command.
         */
        SKIP("skip"),

        /**
         * Try to execute (local applications may intervene by SP control API).
         */
        ATTEMPT("attempt"),
{'fraction_non_alphanumeric': 0.09270976616231087, 'fraction_numerical': 0.005226960110041265, 'mean_word_length': 2.1371872303710093, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 14, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4744124', 'n_tokens_mistral': 1024, 'n_tokens_neox': 966, 'n_words': 292}