import { NativeModules } from 'react-native';
const { MyModule } = NativeModules;
const { CustomMethods } = NativeModules

import { Platform } from 'react-native';


export function AddMarker(lnglat: String) {
  if (Platform.OS === 'ios') {
    CustomMethods.AddMarker(lnglat)
  }else{
    MyModule.AddMarker(lnglat)
  }
 
}

export function AddCustomMarker(lnglat: String) {
  if (Platform.OS === 'ios') {
   
  }else{
    MyModule.AddCustomMarker(lnglat)
  }
 
}

export function SetCameraAnimation(lnglat: String, zoom: String) {
  if (Platform.OS === 'ios') {
    CustomMethods.SetCameraAnimation(lnglat , zoom)
  }else{
    MyModule.SetCameraAnimation(lnglat, zoom)
  }
  
}

export function CameraCallback () {
    MyModule.CameraCallback('Hello from React Native!')
    .then((result: any) => {
      console.warn(result)
    })
    .catch((error: any) => {
      console.warn(error)
    });
  
}




