1export declare type StringBoolean = 'true' | 'false';
2declare type ManifestMetaDataAttributes = AndroidManifestAttributes & {
3    'android:value'?: string;
4    'android:resource'?: string;
5};
6declare type AndroidManifestAttributes = {
7    'android:name': string | 'android.intent.action.VIEW';
8    'tools:node'?: string | 'remove';
9};
10declare type ManifestAction = {
11    $: AndroidManifestAttributes;
12};
13declare type ManifestCategory = {
14    $: AndroidManifestAttributes;
15};
16declare type ManifestData = {
17    $: {
18        [key: string]: string | undefined;
19        'android:host'?: string;
20        'android:pathPrefix'?: string;
21        'android:scheme'?: string;
22    };
23};
24declare type ManifestReceiver = {
25    $: AndroidManifestAttributes & {
26        'android:exported'?: StringBoolean;
27        'android:enabled'?: StringBoolean;
28    };
29    'intent-filter'?: ManifestIntentFilter[];
30};
31export declare type ManifestIntentFilter = {
32    $?: {
33        'android:autoVerify'?: StringBoolean;
34        'data-generated'?: StringBoolean;
35    };
36    action?: ManifestAction[];
37    data?: ManifestData[];
38    category?: ManifestCategory[];
39};
40export declare type ManifestMetaData = {
41    $: ManifestMetaDataAttributes;
42};
43declare type ManifestServiceAttributes = AndroidManifestAttributes & {
44    'android:enabled'?: StringBoolean;
45    'android:exported'?: StringBoolean;
46    'android:permission'?: string;
47};
48declare type ManifestService = {
49    $: ManifestServiceAttributes;
50    'intent-filter'?: ManifestIntentFilter[];
51};
52declare type ManifestApplicationAttributes = {
53    'android:name': string | '.MainApplication';
54    'android:icon'?: string;
55    'android:roundIcon'?: string;
56    'android:label'?: string;
57    'android:allowBackup'?: StringBoolean;
58    'android:largeHeap'?: StringBoolean;
59    'android:requestLegacyExternalStorage'?: StringBoolean;
60    'android:usesCleartextTraffic'?: StringBoolean;
61    [key: string]: string | undefined;
62};
63export declare type ManifestActivity = {
64    $: ManifestApplicationAttributes & {
65        'android:exported'?: StringBoolean;
66        'android:launchMode'?: string;
67        'android:theme'?: string;
68        'android:windowSoftInputMode'?: string | 'stateUnspecified' | 'stateUnchanged' | 'stateHidden' | 'stateAlwaysHidden' | 'stateVisible' | 'stateAlwaysVisible' | 'adjustUnspecified' | 'adjustResize' | 'adjustPan';
69        [key: string]: string | undefined;
70    };
71    'intent-filter'?: ManifestIntentFilter[];
72};
73export declare type ManifestUsesLibrary = {
74    $: AndroidManifestAttributes & {
75        'android:required'?: StringBoolean;
76    };
77};
78export declare type ManifestApplication = {
79    $: ManifestApplicationAttributes;
80    activity?: ManifestActivity[];
81    service?: ManifestService[];
82    receiver?: ManifestReceiver[];
83    'meta-data'?: ManifestMetaData[];
84    'uses-library'?: ManifestUsesLibrary[];
85};
86declare type ManifestPermission = {
87    $: AndroidManifestAttributes & {
88        'android:protectionLevel'?: string | 'signature';
89    };
90};
91export declare type ManifestUsesPermission = {
92    $: AndroidManifestAttributes;
93};
94declare type ManifestUsesFeature = {
95    $: AndroidManifestAttributes & {
96        'android:glEsVersion'?: string;
97        'android:required': StringBoolean;
98    };
99};
100export declare type AndroidManifest = {
101    manifest: {
102        $: {
103            'xmlns:android': string;
104            'xmlns:tools'?: string;
105            package?: string;
106            [key: string]: string | undefined;
107        };
108        permission?: ManifestPermission[];
109        'uses-permission'?: ManifestUsesPermission[];
110        'uses-permission-sdk-23'?: ManifestUsesPermission[];
111        'uses-feature'?: ManifestUsesFeature[];
112        application?: ManifestApplication[];
113    };
114};
115export declare function writeAndroidManifestAsync(manifestPath: string, androidManifest: AndroidManifest): Promise<void>;
116export declare function readAndroidManifestAsync(manifestPath: string): Promise<AndroidManifest>;
117/** Returns the `manifest.application` tag ending in `.MainApplication` */
118export declare function getMainApplication(androidManifest: AndroidManifest): ManifestApplication | null;
119export declare function getMainApplicationOrThrow(androidManifest: AndroidManifest): ManifestApplication;
120export declare function getMainActivityOrThrow(androidManifest: AndroidManifest): ManifestActivity;
121export declare function getRunnableActivity(androidManifest: AndroidManifest): ManifestActivity | null;
122export declare function getMainActivity(androidManifest: AndroidManifest): ManifestActivity | null;
123export declare function addMetaDataItemToMainApplication(mainApplication: ManifestApplication, itemName: string, itemValue: string, itemType?: 'resource' | 'value'): ManifestApplication;
124export declare function removeMetaDataItemFromMainApplication(mainApplication: any, itemName: string): any;
125export declare function findMetaDataItem(mainApplication: any, itemName: string): number;
126export declare function findUsesLibraryItem(mainApplication: any, itemName: string): number;
127export declare function getMainApplicationMetaDataValue(androidManifest: AndroidManifest, name: string): string | null;
128export declare function addUsesLibraryItemToMainApplication(mainApplication: ManifestApplication, item: {
129    name: string;
130    required?: boolean;
131}): ManifestApplication;
132export declare function removeUsesLibraryItemFromMainApplication(mainApplication: ManifestApplication, itemName: string): ManifestApplication;
133export declare function prefixAndroidKeys<T extends Record<string, any> = Record<string, string>>(head: T): Record<string, any>;
134/**
135 * Ensure the `tools:*` namespace is available in the manifest.
136 *
137 * @param manifest AndroidManifest.xml
138 * @returns manifest with the `tools:*` namespace available
139 */
140export declare function ensureToolsAvailable(manifest: AndroidManifest): AndroidManifest;
141export {};
142