syncthing.api.ApiUtils.java Source code

Java tutorial

Introduction

Here is the source code for syncthing.api.ApiUtils.java

Source

/*
 * Copyright (c) 2015 OpenSilk Productions LLC
 *
 * This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
 *
 */

package syncthing.api;

import org.apache.commons.lang3.builder.ReflectionToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

/**
 * Created by drew on 4/11/15.
 */
public class ApiUtils {
    public static <T> String reflectionToString(T obj) {
        return ReflectionToStringBuilder.toString(obj, ToStringStyle.SHORT_PREFIX_STYLE, true);
    }
}