
먼저 https://apps.apple.com/kr/app/realm-browser/id1007457278?mt=12
Realm Browser
Realm Browser is a viewer and editor for .realm data store files. It allows developers implementing Realm in their apps to easily view and debug the contents of the .realm files their apps have created. Features: - View all of the objects in a .realm file
apps.apple.com
맥용 Realm Browser 를 설치해 줍니다.
설치후 실행해 보면 아래와 같은 화면을 볼수 있습니다.
자 이제 Realm File 을 찾으러 가봅시다.
Simulator Device 기준 입니다 !
찾기전에 Realm을 이용해서 DB 를 구성해 주세요.
Realm 적용 방법은
https://sweetcoding.tistory.com/51?category=732018 를 참고해 주세요.
먼저 Realm File 의 경로를 찾기 위해서 다음과 같이
Console 에 출력을 해줍니다.
print("path = \(Realm.Configuration.defaultConfiguration.fileURL!)")
그럼 콘솔창에
와 같이 출력이 됩니다.
그럼 해당 파일을 찾아 가봅시다.
Finder 를 켜주고 cmd + shift + g 키를 눌러줍니다.
/Users/xxxxxx/Library/Developer/CoreSimulator/Devices/84D9E630-ABD4-43F9-8C05-EA8337DC2968/data/Containers/Data/Application/70F66B75-7ECB-40E8-A24A-46926086EE92/Documents/
입력창에 그림 2 에서 나온 경로중 file:// 와 뒤에 파일 이름 default.realm 을 뺀 나머지를 입력해 줍니다.
과 같은 페이지를 찾으면 default.realm 파일을 복사하여 찾기 쉬운 곳 에 놓아줍니다.
다음으로 그림 1 의 Open Realm File 을 눌러서 복사한 파일을 선택하여 열어줍니다.
그럼 자신이 저장한 Realm Data를 확인할 수 있습니다.
'공부방 > iOS' 카테고리의 다른 글
When iOS notification click remove all that how to block ? (0) | 2019.08.09 |
---|---|
Tip of update data in swift realm (0) | 2019.07.31 |
Using Codable with Realm(Codable 과 Realm 동시 사용) (0) | 2019.07.26 |
AsyncSubject, PublishSubject, BehaviorSubject, ReplaySubject (0) | 2019.07.24 |
iOS Firebase Analytics apply (iOS Firebase Analytics 적용) (0) | 2019.07.15 |
행복한 코딩을 위하여!
포스팅이 좋았다면 "좋아요❤️" 또는 "구독👍🏻" 해주세요!