Skip to content

SiddharthChopra/FindViewControl

 
 

Repository files navigation

FindViewControl

LogCamp

FindViewControl is written in Swift

Installation

CocoaPods

CocoaPods is a dependency manager for Cocoa projects.

pod 'FindViewControl', :git => 'https://github.com/Kruks/FindViewControl.git', :tag => '1.0.12'

Also, add below code at the end of the pod file

pre_install do |installer|
    def installer.verify_no_static_framework_transitive_dependencies; end
end

Add FindViewControl To Project

Initial Setup:

You need to add GoogleMaps framework manually, for that go to "Pods" project, select target "FindViewControl" goto Build Phases in "Link Binary With Libraries" add GoogleMaps.framework from project. Also in Build Settings in "Framework Search Paths", please verify the below two paths are added for both debug & release(If not, add it manually):-

"${PODS_ROOT}/GoogleMaps/Base/Frameworks"
"${PODS_ROOT}/GoogleMaps/Maps/Frameworks"

Swift Code:

(Add this code in viewdidload for viewcontroller)
// Initialize Picker for filter

      let pickerArray = [FilterObject]()
        
        let fobj = FilterObject()
        fobj.filterID = "fire_station"
        fobj.filterValue = "FireStation"
        pickerArray.append(fobj)
        
        let fobj1 = FilterObject()
        fobj1.filterID = "gas_station"
        fobj1.filterValue = "gas_station"
        pickerArray.append(fobj1)

// Init Find Control

 _ =  FindControl.init(viewController: self,googleAPIKey: "AIzXXXXXXXXXXXXXXXXXX8sk",useGooglePlaces: true, filterArray: pickerArray, gisURL: "GIS validation URl", googlePlacesKey: "AIzaXXXXXXXXXXXXXXXXXXFFMc", defaultLattitude: 34.052235, defaultLongitude: -118.243683, defaultAddress: "test")
 

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Swift 78.1%
  • Objective-C 21.2%
  • Ruby 0.7%