<?xml version='1.0' encoding='utf-8'?>
<plugin 
id="cordova-plugin-httpd-webserver"
version="1.0.0"
xmlns="http://apache.org/cordova/ns/plugins/1.0" 
xmlns:android="http://schemas.android.com/apk/res/android">

<name>Httpd</name>
<description>Httpd is an plugin to embed a httpd (web server) into Cordova Android and ios</description>
<author>Angiolini Leandro</author>
<license>MIT</license>
<keywords>httpd,web,server,http,android,ios</keywords>
<repo>https://gitlab.com/bidi2020-grp/cordova-plugin-httpd-webserver.git</repo>
<issue>https://gitlab.com/bidi2020-grp/cordova-plugin-httpd-webserver/issues</issue>

<engines>
    <engine name="cordova" version=">=2.9" />
    <engine name="cordova-osx" version=">=4.0.0" />
</engines>

<js-module name="Httpd" src="www/Httpd.js">
<clobbers target="cordova.plugins.Httpd" />
</js-module>

<platform name="android">

<config-file parent="/*" target="res/xml/config.xml">
<feature name="Httpd">
<param name="android-package" value="com.ticmas.cordova.webserver.Httpd" />
</feature>
</config-file>

<config-file target="AndroidManifest.xml" parent="/*">
    <uses-permission android:name="android.permission.INTERNET" />
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
</config-file>

<source-file src="src/android/Httpd.java" target-dir="src/com/ticmas/cordova/webserver" />
<source-file src="src/android/AndroidFile.java" target-dir="src/com/ticmas/cordova/webserver" />
<source-file src="src/android/NanoHTTPD.java" target-dir="src/com/ticmas/cordova/webserver" />
<source-file src="src/android/WebServer.java" target-dir="src/com/ticmas/cordova/webserver" />

</platform>

<platform name="ios">

<config-file parent="/*" target="config.xml">
<feature name="Httpd">
<param name="ios-package" value="Httpd" />
</feature>
</config-file>

<source-file src="src/ios/Httpd.m" />

<header-file src="src/ios/CocoaHttpd/HTTPLogging.h" />
<header-file src="src/ios/CocoaHttpd/HTTPServer.h" />
<source-file src="src/ios/CocoaHttpd/HTTPServer.m" />
<header-file src="src/ios/CocoaHttpd/WebSocket.h" />
<source-file src="src/ios/CocoaHttpd/WebSocket.m" />
<header-file src="src/ios/CocoaHttpd/HTTPMessage.h" />
<source-file src="src/ios/CocoaHttpd/HTTPMessage.m" />
<header-file src="src/ios/CocoaHttpd/HTTPAuthenticationRequest.h" />
<source-file src="src/ios/CocoaHttpd/HTTPAuthenticationRequest.m" />
<header-file src="src/ios/CocoaHttpd/HTTPConnection.h" />
<source-file src="src/ios/CocoaHttpd/HTTPConnection.m" />
<header-file src="src/ios/CocoaHttpd/HTTPResponse.h" />
<header-file src="src/ios/CocoaHttpd/Responses/HTTPAsyncFileResponse.h" />
<source-file src="src/ios/CocoaHttpd/Responses/HTTPAsyncFileResponse.m" />
<header-file src="src/ios/CocoaHttpd/Responses/HTTPErrorResponse.h" />
<source-file src="src/ios/CocoaHttpd/Responses/HTTPErrorResponse.m" />
<header-file src="src/ios/CocoaHttpd/Responses/HTTPDynamicFileResponse.h" />
<source-file src="src/ios/CocoaHttpd/Responses/HTTPDynamicFileResponse.m" />
<header-file src="src/ios/CocoaHttpd/Responses/HTTPRedirectResponse.h" />
<source-file src="src/ios/CocoaHttpd/Responses/HTTPRedirectResponse.m" />
<header-file src="src/ios/CocoaHttpd/Responses/HTTPFileResponse.h" />
<source-file src="src/ios/CocoaHttpd/Responses/HTTPFileResponse.m" />
<header-file src="src/ios/CocoaHttpd/Responses/HTTPDataResponse.h" />
<source-file src="src/ios/CocoaHttpd/Responses/HTTPDataResponse.m" />
<header-file src="src/ios/CocoaHttpd/Mime/MultipartFormDataParser.h" />
<source-file src="src/ios/CocoaHttpd/Mime/MultipartFormDataParser.m" />
<header-file src="src/ios/CocoaHttpd/Mime/MultipartMessageHeader.h" />
<source-file src="src/ios/CocoaHttpd/Mime/MultipartMessageHeader.m" />
<header-file src="src/ios/CocoaHttpd/Mime/MultipartMessageHeaderField.h" />
<source-file src="src/ios/CocoaHttpd/Mime/MultipartMessageHeaderField.m" />
<header-file src="src/ios/CocoaHttpd/Categories/DDData.h" />
<source-file src="src/ios/CocoaHttpd/Categories/DDData.m" />
<header-file src="src/ios/CocoaHttpd/Categories/DDNumber.h" />
<source-file src="src/ios/CocoaHttpd/Categories/DDNumber.m" />
<header-file src="src/ios/CocoaHttpd/Categories/DDRange.h" />
<source-file src="src/ios/CocoaHttpd/Categories/DDRange.m" />
<header-file src="src/ios/CocoaHttpd/Vendor/CocoaAsyncSocket/GCDAsyncSocket.h" />
<source-file src="src/ios/CocoaHttpd/Vendor/CocoaAsyncSocket/GCDAsyncSocket.m" />
<source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDAbstractDatabaseLogger.h" />
<source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDAbstractDatabaseLogger.m" />
<header-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDFileLogger.h" />
<source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDFileLogger.m" />
<header-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDASLLogger.h" />
<source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDASLLogger.m" />
<header-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDTTYLogger.h" />
<source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDTTYLogger.m" />
<header-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDLog.h" />
<source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDLog.m" />
<header-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/Extensions/ContextFilterLogFormatter.h" />
<source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/Extensions/ContextFilterLogFormatter.m" />
<header-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/Extensions/DispatchQueueLogFormatter.h" />
<source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/Extensions/DispatchQueueLogFormatter.m" />

<framework src="CFNetwork.framework" />
<framework src="Foundation.framework" />
<framework src="Security.framework" />

</platform>

    <platform name="osx">
        <config-file parent="/*" target="config.xml">
            <feature name="Httpd">
                <param name="ios-package" value="Httpd" />
            </feature>
        </config-file>

        <!-- OSX and iOS share the same sources -->
        <source-file src="src/ios/Httpd.m" />
        <header-file src="src/ios/CocoaHttpd/HTTPLogging.h" />
        <header-file src="src/ios/CocoaHttpd/HTTPServer.h" />
        <source-file src="src/ios/CocoaHttpd/HTTPServer.m" />
        <header-file src="src/ios/CocoaHttpd/WebSocket.h" />
        <source-file src="src/ios/CocoaHttpd/WebSocket.m" />
        <header-file src="src/ios/CocoaHttpd/HTTPMessage.h" />
        <source-file src="src/ios/CocoaHttpd/HTTPMessage.m" />
        <header-file src="src/ios/CocoaHttpd/HTTPAuthenticationRequest.h" />
        <source-file src="src/ios/CocoaHttpd/HTTPAuthenticationRequest.m" />
        <header-file src="src/ios/CocoaHttpd/HTTPConnection.h" />
        <source-file src="src/ios/CocoaHttpd/HTTPConnection.m" />
        <header-file src="src/ios/CocoaHttpd/HTTPResponse.h" />
        <header-file src="src/ios/CocoaHttpd/Responses/HTTPAsyncFileResponse.h" />
        <source-file src="src/ios/CocoaHttpd/Responses/HTTPAsyncFileResponse.m" />
        <header-file src="src/ios/CocoaHttpd/Responses/HTTPErrorResponse.h" />
        <source-file src="src/ios/CocoaHttpd/Responses/HTTPErrorResponse.m" />
        <header-file src="src/ios/CocoaHttpd/Responses/HTTPDynamicFileResponse.h" />
        <source-file src="src/ios/CocoaHttpd/Responses/HTTPDynamicFileResponse.m" />
        <header-file src="src/ios/CocoaHttpd/Responses/HTTPRedirectResponse.h" />
        <source-file src="src/ios/CocoaHttpd/Responses/HTTPRedirectResponse.m" />
        <header-file src="src/ios/CocoaHttpd/Responses/HTTPFileResponse.h" />
        <source-file src="src/ios/CocoaHttpd/Responses/HTTPFileResponse.m" />
        <header-file src="src/ios/CocoaHttpd/Responses/HTTPDataResponse.h" />
        <source-file src="src/ios/CocoaHttpd/Responses/HTTPDataResponse.m" />
        <header-file src="src/ios/CocoaHttpd/Mime/MultipartFormDataParser.h" />
        <source-file src="src/ios/CocoaHttpd/Mime/MultipartFormDataParser.m" />
        <header-file src="src/ios/CocoaHttpd/Mime/MultipartMessageHeader.h" />
        <source-file src="src/ios/CocoaHttpd/Mime/MultipartMessageHeader.m" />
        <header-file src="src/ios/CocoaHttpd/Mime/MultipartMessageHeaderField.h" />
        <source-file src="src/ios/CocoaHttpd/Mime/MultipartMessageHeaderField.m" />
        <header-file src="src/ios/CocoaHttpd/Categories/DDData.h" />
        <source-file src="src/ios/CocoaHttpd/Categories/DDData.m" />
        <header-file src="src/ios/CocoaHttpd/Categories/DDNumber.h" />
        <source-file src="src/ios/CocoaHttpd/Categories/DDNumber.m" />
        <header-file src="src/ios/CocoaHttpd/Categories/DDRange.h" />
        <source-file src="src/ios/CocoaHttpd/Categories/DDRange.m" />
        <header-file src="src/ios/CocoaHttpd/Vendor/CocoaAsyncSocket/GCDAsyncSocket.h" />
        <source-file src="src/ios/CocoaHttpd/Vendor/CocoaAsyncSocket/GCDAsyncSocket.m" />
        <source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDAbstractDatabaseLogger.h" />
        <source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDAbstractDatabaseLogger.m" />
        <header-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDFileLogger.h" />
        <source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDFileLogger.m" />
        <header-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDASLLogger.h" />
        <source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDASLLogger.m" />
        <header-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDTTYLogger.h" />
        <source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDTTYLogger.m" />
        <header-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDLog.h" />
        <source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/DDLog.m" />
        <header-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/Extensions/ContextFilterLogFormatter.h" />
        <source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/Extensions/ContextFilterLogFormatter.m" />
        <header-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/Extensions/DispatchQueueLogFormatter.h" />
        <source-file src="src/ios/CocoaHttpd/Vendor/CocoaLumberjack/Extensions/DispatchQueueLogFormatter.m" />

        <framework src="CFNetwork.framework" />
        <framework src="Foundation.framework" />
        <framework src="Security.framework" />
    </platform>
</plugin>
