블로그 이미지
올해목표 // 10월 어학연수 떠나자~ 자수씨

카테고리

전체글 (1457)
Brand New! (28)
주절주절 (213)
MOT (11)
해외쇼핑 (49)
쇼핑노트 (150)
취미생활 (94)
iPhone (4)
Eclipse (121)
Google (83)
Spring (31)
JAVA (176)
JavaScript (59)
WEB (49)
Database (20)
OS (26)
Tools (8)
Tips (26)
IT정보 (1)
Book (21)
Programming (37)
외부행사 (43)
주변인들 (17)
여행노트 (60)
학교생활 (30)
회사생활 (52)
사회생활 (5)
외국어공부 (12)
잡동사니 (30)
Total
Today
Yesterday
 
03-29 02:17
 

달력

« » 2024.3
1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
31
 

최근에 올라온 글

최근에 달린 댓글

'GoogleGears'에 해당되는 글 1건

  1. 2008.02.09 [Google Gears] LocalServer Module API

LocalServer Module
출처: http://code.google.com/apis/gears/api_localserver.html

네트워크 연결이 끊긴 상태에서도 웹 어플리케이션의 HTTP 리소스들을 로컬에 저장하고 제공해주는 역할을 한다.

Resource Stores
 - ResourceStore : 자바스크립트를 이용하여 임시의 URL들을 캡쳐링
 - ManagedResourceStore : manifest 파일에 선언된 URL들을 캡쳐링

Updating of cached resources
 - ManagedResourceStore는 manifest 파일의 버전이 변경될 경우 자동적으로 업데이트를 한다.
   (checkForUpdate() 메소드를 이용)
 - ResourceStore는 웹 어플리케이션에 의해 변경된다. (자동 업데이트 X)

Local serving of cached resources
 - LocalServer는 HTTP/HTTPS 요청을 캐싱된 데이터를 이용하여 상황에 맞게 제공해준다.
 - 네트워크 상태와는 상관없이 요청된 URL이 캐싱된 경우에는 캐싱된 리소스들로 처리한다.

LocalServer Class
 로컬서버는 Gears Factory를 통하여 생성된다.



ManagedResourceStore Class

ResourceStore Class

FileSubmitter Class

Manifest File

{
	// version of the manifest file format
	"betaManifestVersion": 1,

	// version of the set of resources described in this manifest file
	"version": "my_version_string",

	// optional
	// If the store specifies a requiredCookie, when a request would hit
	// an entry contained in the manifest except the requiredCookie is
	// not present, the local server responds with a redirect to this URL.
	"redirectUrl": "login.html",
	// URLs to be cached (URLs are given relative to the manifest URL)
	"entries": [
		{ "url": "main.html", "src": "main_offline.html" },
		{ "url": ".", "redirect": "main.html" },
		{ "url": "main.js" }
		{ "url": "formHandler.html", "ignoreQuery": true },
	]
}


Posted by 자수씨
, |

글 보관함

최근에 받은 트랙백