<?php

const FB_SETUP = [
    "app_id" => "333145007149186",
    "app_secret" => "0829ca8355f285c2ed1215db8313d8c9",
    "default_graph_version" => "v2.10",
    "default_access_token" => "333145007149186|rQbHNX_vBfiOW5mhddYVr6DPuMU",
];

const REQUEST_TYPES = [
// generates: ?fields=posts{from,message,created_time}
    "get_posts" => [
        "edgeName" => "",
        "fieldsArr" => ["posts"],
        "subFieldsArr" => ["from", "message", "created_time"],
        "conversionFnName" => "getDecodedBody",
    ],
// generates: ?fields=comments{created_time,message,id,from}
    "get_comments" => [
        "edgeName" => "",
        "fieldsArr" => ["comments"],
        "subFieldsArr" => ["from", "message", "created_time"],
        "conversionFnName" => "getDecodedBody",
    ],
];

//     this is the 'skeleton' structure of the generic types of elements
const DATA_HIERARCHY = [
    "page" => [
        "hierarchy_level" => 10,
        "children" => ["post"],
        "api_function" => "get_posts"
    ],
    "group" => [
        "hierarchy_level" => 10,
        "children" => ["post"],
        "api_function" => "get_posts"
    ],
    "user" => [
        "hierarchy_level" => 10,
        "children" => ["post"],
        "api_function" => "get_posts"
    ],
    "event" => [
        "hierarchy_level" => 10,
        "children" => ["post"],
        "api_function" => "get_posts"
    ],
    "post" => [
        "hierarchy_level" => 20,
        "children" => ["comment"],
        "api_function" => "get_comments"
    ],
    "comment" => [
        "hierarchy_level" => 30,
        "children" => [],
        "api_function" => []
    ],
];

const FB_DEFAULTS = [
    "entity_type" => [
        "start" => "page",
        "end" => "comment"
    ],
    "data_set" => "egypt-1",
    "file_extension" => "txt",
    "file_format" => "file",
    "extradata_format" => "json",
    "message_format" => "txt",
    "list_format" => "array",
    "project_name" => "beara", // code name
    "data_set_name" => "egypt_pages",
    "facebook_url_prefix" => "facebook.com/",
    "source_type" => "Facebook",
    "date_length" => 19,
    "doc_text_dir" => "text",
    "doc_extradata_dir" => "extradata",
    "timeOfCollectFbData"=>'4:00 am',
    "timeOfAnalyzeFbData"=>'7:00 am'
];
