Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
//License from project: Apache License 

public class Main {
    private static final String[] VIDEO_WITNESS = { "video", "mp4", "h26", "ogg", "avi", "divx" };

    static boolean isVLCVideoMimeType(String mimeType) {
        return is_part_of(VIDEO_WITNESS, mimeType.toLowerCase());

    }

    private static boolean is_part_of(String[] parts, String of) {
        for (int i = 0; i < parts.length; i++)
            if (of.indexOf(parts[i]) != -1)
                return true;

        return false;

    }
}