SlideShare a Scribd company logo
1 of 51
이종인
*바람 인터렉티브 Founder
*Windows Platform Development MVP
* Windows Phone 앱 개발
-
-
lunelake@outlook.com
http://www.facebook.com/BaramInteractive design me
다른 사람과 떠들고 싶다
일상들의 아름다운 순간들을 남기고
주변사람들과 공유하고 싶다
음악을 마음껏 듣고 싶다
맛 집 정보를 얻고 싶다
건강을 관리하고 싶다
빠르게 기록하고 정리하고 싶다
+
놀고 싶다
사람들에게 도움이 되는 무언가를 만들어서
많은 사람들이 쓰게 하고 싶다+
+
서비스를 많은 사람들이 쓰게 하는 방법
더 이상 집에 컴퓨터 한대 놓여 있는 게 아닌 세상
다양한 디바이스에서도 끊임 없는 경험의 연결
Web
현재의 앱&서비스 개발 프로세스
Web
서비스 업데이트 및 에러 발생 시
데스크탑부터 랩탑, 태블릿, 폰까지
Windows 10에서의 앱 사용환경의 변화
Windows 10으로 1년 내 업그레이드 시 무료
데스크탑, 태블릿, 폰을 아우르는 서비스를 한 프로젝트에서
(Shared project, PCL)
Shared Project
화면 크기에 대응하는 UI x
화면 크기에 대응하는 UI
7”
6”
5”
4.5”
Infinite virtual canvas
x
y
PortraitLandscape
디바이스의 크기와 환경에 따라 달라지는 유저들의 요구와
그로 인해 파편화된 경험들 합치기
플랫폼의 의존성을 줄인 디자인
+
Grid.Row xGrid.Column
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="100" />
<ColumnDefinition Width=“Auto" />
<ColumnDefinition Width="100" />
</Grid.ColumnDefinitions>
<Rectangle Grid.Column=“0" Grid.ColumnSpan=“2" />
</Grid>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height=“100" />
<RowDefinition Height=“Auto" />
<RowDefinition Height=“100" />
</Grid. RowDefinitions>
<Rectangle Grid.Row=“1" />
</Grid>
0
1
2
0 1 2
Grid 화면크기에 대응
x
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width=“50" />
<ColumnDefinition Width=“1*" />
<ColumnDefinition Width="1*" />
<ColumnDefinition Width=“50" />
</Grid.ColumnDefinitions>
</Grid>
50 501* 1*
50 501* 1* 50 501* 1*
Viewbox x
Viewbox
Control
Viewbox x
<Grid Background="Black">
<GridView Margin="100,100,0,0">
<Rectangle Fill="Red" Height="200" Width="200" />
<Rectangle Fill="Red" Height="200" Width="200" />
<Rectangle Fill="Red" Height="200" Width="200" />
<Rectangle Fill="Red" Height="200" Width="200" />
<Rectangle Fill="Red" Height="200" Width="200" />
</GridView>
</Grid>
<Grid Background="Black">
<Viewbox HorizontalAlignment="Left">
<GridView Margin="100,100,0,0" Height="768" >
<Rectangle Fill="Red" Height="200" Width="200" />
<Rectangle Fill="Red" Height="200" Width="200" />
<Rectangle Fill="Red" Height="200" Width="200" />
<Rectangle Fill="Red" Height="200" Width="200" />
<Rectangle Fill="Red" Height="200" Width="200" />
</GridView>
</Viewbox>
</Grid>
Element 비율 따라 크기 조정 Element 크기 조정
윈도우 사이즈가 변했을 때 x
protected override void OnNavigatedTo(NavigationEventArgs e)
{
this.navigationHelper.OnNavigatedTo(e);
Window.Current.SizeChanged += Current_SizeChanged;
}
protected override void OnNavigatedFrom(NavigationEventArgs e)
{
this.navigationHelper.OnNavigatedFrom(e);
Window.Current.SizeChanged -= Current_SizeChanged;
}
/// <summary>
/// 윈도우의 사이즈가 변했을 때 이벤트
/// </summary>
public void Current_SizeChanged(object sender, Windows.UI.Core.WindowSizeChangedEventArgs e)
{
double windowWidth = e.Size.Width;
double windowHeight = e.Size.Height;
//로직
}
여러 디바이스간 데이터 연결
윈도우 기기간 데이터 동기화
즉결성 보장X)
비용 지출X 비용 지출O
Roaming storage를 통한 데이터 동기화
StorageFolder roamingFolder = ApplicationData.Current.RoamingFolder;
public async void SaveText(string saveText)
{
StorageFile sampleFile = await roamingFolder.CreateFileAsync("dataFile.txt",
CreationCollisionOption.ReplaceExisting);
await FileIO.WriteTextAsync(sampleFile, saveText);
}
ApplicationDataContainer roamingSettings = ApplicationData.Current.RoamingSettings;
public void SaveSetting()
{
roamingSettings.Values["exampleSetting"] = "Hello World";
roamingSettings.Values["HighPriority"] = "65";
}
설정 저장
텍스트 저장
OnlineIdAuthenticator를 통한 Onedrive 동기화
public class WindowsAccountAuthenticator
{
OnlineIdAuthenticator authenticator;
public WindowsAccountAuthenticator()
{
authenticator = new OnlineIdAuthenticator();
}
/// <summary>
/// 마이크로소프트 계정 로그인 및 인증
/// </summary>
public async Task SignIn()
{
var targetArray = new List<OnlineIdServiceTicketRequest>();
targetArray.Add(new OnlineIdServiceTicketRequest("wl.signin", "DELEGATION"));
var result = await authenticator.AuthenticateUserAsync(targetArray, CredentialPromptType.PromptIfNeeded);
string AccessToken = result.Tickets[0].Value;
}
}
OnlineIdAuthenticator를 통한 Onedrive 동기화
Credential Locker
MSA
void SaveCredential(string username, string password)
{
PasswordVault vault = new PasswordVault();
PasswordCredential cred = new
PasswordCredential("MyAppResource", username, password);
vault.Add(cred);
}
IReadOnlyList<PasswordCredential> RetrieveCredential(string
resource)
{
PasswordVault vault = new PasswordVault();
return vault.FindAllByResource(resource);
}
애저 모바일 서비스
Custom API 스케줄러 푸시
저장소
(용량 제한)
C#
Javascript
Custom API
Ex)TimeChecker
요청
현재 시간
체크
현재시간
리턴
https://{ServiceName}.azure-mobile.net/api/{API Name}
Rest API
C# - SDK
DateTimeOffset result = await
App.{MobileServiceClientName}.InvokeApiAsync<DateTimeOffset>
(“{API Name}", HttpMethod.Get, null);
"2015-01-30T13:26:11.829Z"
리턴
Push Notification
Azure Mobile
Service
Push
wns apns gcm
// windows
var toast = @"<toast><visual>
<binding template=""ToastText01"">
<text id=""1"">Hello</text></binding></visual></toast>";
await
Notifications.Instance.Hub.SendWindowsNativeNotificationAsync(toast,userTag);
// apns
var alert = "{"aps":{"alert":"Hello"}}";
await
Notifications.Instance.Hub.SendAppleNativeNotificationAsync(alert,userTag);
// gcm
var notif = "{ "data" : {"msg":"Hello"}}";
await
Notifications.Instance.Hub.SendGcmNativeNotificationAsync(notif,userTag);
디바이스간 데이터 동기화 시나리오
Azure Mobile
Service
Push
notification 동기화 앱 켜질시
동기화
서비스에서의 웹 서비스 활용
Azure Mobile
Service
Azure Web
Service
Design Me에서의 PCL 사용
PCL
Azure
Web Service
Azure
Mobile Service
(Shared code, logic, datamodel.. Etc)
Universal
Windows App
Data model 공유
PCL
Universal
App
Mobile Service
Controller
public class Request
{
public string request { get; set; }
}
public class Result
{
public string result { get; set; }
}
Controller
public async Task<HttpResponseMessage>
Post(Request request)
{
Result result = new Result();
//처리
return Request.CreateResponse
(HttpStatusCode.OK, result);
}
Request
Request request = new Request()
Result result = await App.{ClientName}
.InvokeApiAsync<Request, Result>
(“APIName", request);
플랫폼간 긴밀하게 연결되는 서비스
C#
PCL
Universal
Windows App A
z
u
r
e
Web
현재의 개발 프로세스
Web
Azure와 Xamarin, PCL을 활용한 개발 프로세스
Windows
유니버셜 앱의 가능성

More Related Content

Similar to 유니버셜 앱의 가능성

[Td 2015]70분에 보여준다. 웹표준을 지원하는 edge 브라우저부터 웹 앱 개발까지(김영욱)
[Td 2015]70분에 보여준다. 웹표준을 지원하는 edge 브라우저부터 웹 앱 개발까지(김영욱)[Td 2015]70분에 보여준다. 웹표준을 지원하는 edge 브라우저부터 웹 앱 개발까지(김영욱)
[Td 2015]70분에 보여준다. 웹표준을 지원하는 edge 브라우저부터 웹 앱 개발까지(김영욱)Sang Don Kim
 
Web UI/UX in the Multi device & Multi Screen Environment
Web UI/UX in the Multi device & Multi Screen EnvironmentWeb UI/UX in the Multi device & Multi Screen Environment
Web UI/UX in the Multi device & Multi Screen EnvironmentJonathan Jeon
 
Mobile UX for Windows Mobile
Mobile UX for Windows MobileMobile UX for Windows Mobile
Mobile UX for Windows MobileSeo Jinho
 
차세대 웹 환경에서의 UI/UX 기술 표준화 동향
차세대 웹 환경에서의 UI/UX 기술 표준화 동향차세대 웹 환경에서의 UI/UX 기술 표준화 동향
차세대 웹 환경에서의 UI/UX 기술 표준화 동향Jonathan Jeon
 
HTML5 융합 기술 표준화 동향
HTML5 융합 기술 표준화 동향HTML5 융합 기술 표준화 동향
HTML5 융합 기술 표준화 동향Jonathan Jeon
 
Requirement analysis for the production of educational hybrid web applications
Requirement analysis for the production of educational hybrid web applicationsRequirement analysis for the production of educational hybrid web applications
Requirement analysis for the production of educational hybrid web applicationsKwangChul Kim
 
앱이냐?웹이냐?
앱이냐?웹이냐?앱이냐?웹이냐?
앱이냐?웹이냐?Chulgyu Shin
 
앱이냐?웹이냐?
앱이냐?웹이냐?앱이냐?웹이냐?
앱이냐?웹이냐?Chulgyu Shin
 
ClouDoc intro_eng_20161121
ClouDoc intro_eng_20161121ClouDoc intro_eng_20161121
ClouDoc intro_eng_20161121sang yoo
 
[141]지난 1년간의 웨일 브라우저와 그 미래 (부제: 제품 매니저가 들려주는 생생한 기술/제품 이야기)
[141]지난 1년간의 웨일 브라우저와 그 미래 (부제: 제품 매니저가 들려주는 생생한 기술/제품 이야기)[141]지난 1년간의 웨일 브라우저와 그 미래 (부제: 제품 매니저가 들려주는 생생한 기술/제품 이야기)
[141]지난 1년간의 웨일 브라우저와 그 미래 (부제: 제품 매니저가 들려주는 생생한 기술/제품 이야기)NAVER D2
 
2012, 대한민국 웹 표준, 그 기로에 서다
2012, 대한민국 웹 표준, 그 기로에 서다2012, 대한민국 웹 표준, 그 기로에 서다
2012, 대한민국 웹 표준, 그 기로에 서다Jonathan Jeon
 
H3 2011 반응형 웹디자인,진짜 할 만 한가?_Fi팀_신현석
H3 2011 반응형 웹디자인,진짜 할 만 한가?_Fi팀_신현석H3 2011 반응형 웹디자인,진짜 할 만 한가?_Fi팀_신현석
H3 2011 반응형 웹디자인,진짜 할 만 한가?_Fi팀_신현석KTH, 케이티하이텔
 
H3 2011 반응형 웹디자인, 진짜 할 만 한가?
H3 2011 반응형 웹디자인, 진짜 할 만 한가?H3 2011 반응형 웹디자인, 진짜 할 만 한가?
H3 2011 반응형 웹디자인, 진짜 할 만 한가?KTH
 
mobile platform
mobile platformmobile platform
mobile platformash84
 
Mobile Platform
Mobile PlatformMobile Platform
Mobile Platformash84
 
The personalcloud 20100505
The personalcloud 20100505The personalcloud 20100505
The personalcloud 20100505jhpark
 
The personal cloud
The personal cloudThe personal cloud
The personal cloudjhpark
 
질병관리본부 특강 - 모바일 “고해상도 디스플레이” 시대를 준비하다
질병관리본부 특강 - 모바일 “고해상도 디스플레이”  시대를 준비하다질병관리본부 특강 - 모바일 “고해상도 디스플레이”  시대를 준비하다
질병관리본부 특강 - 모바일 “고해상도 디스플레이” 시대를 준비하다yamoo9
 
DEC2010 Track C-2 실버라이트로 시작하는 윈도우폰7의 만남
DEC2010 Track C-2 실버라이트로 시작하는 윈도우폰7의 만남DEC2010 Track C-2 실버라이트로 시작하는 윈도우폰7의 만남
DEC2010 Track C-2 실버라이트로 시작하는 윈도우폰7의 만남Hyeon Cheol Pak
 

Similar to 유니버셜 앱의 가능성 (20)

[Td 2015]70분에 보여준다. 웹표준을 지원하는 edge 브라우저부터 웹 앱 개발까지(김영욱)
[Td 2015]70분에 보여준다. 웹표준을 지원하는 edge 브라우저부터 웹 앱 개발까지(김영욱)[Td 2015]70분에 보여준다. 웹표준을 지원하는 edge 브라우저부터 웹 앱 개발까지(김영욱)
[Td 2015]70분에 보여준다. 웹표준을 지원하는 edge 브라우저부터 웹 앱 개발까지(김영욱)
 
Web UI/UX in the Multi device & Multi Screen Environment
Web UI/UX in the Multi device & Multi Screen EnvironmentWeb UI/UX in the Multi device & Multi Screen Environment
Web UI/UX in the Multi device & Multi Screen Environment
 
Mobile UX for Windows Mobile
Mobile UX for Windows MobileMobile UX for Windows Mobile
Mobile UX for Windows Mobile
 
차세대 웹 환경에서의 UI/UX 기술 표준화 동향
차세대 웹 환경에서의 UI/UX 기술 표준화 동향차세대 웹 환경에서의 UI/UX 기술 표준화 동향
차세대 웹 환경에서의 UI/UX 기술 표준화 동향
 
HTML5 융합 기술 표준화 동향
HTML5 융합 기술 표준화 동향HTML5 융합 기술 표준화 동향
HTML5 융합 기술 표준화 동향
 
Requirement analysis for the production of educational hybrid web applications
Requirement analysis for the production of educational hybrid web applicationsRequirement analysis for the production of educational hybrid web applications
Requirement analysis for the production of educational hybrid web applications
 
앱이냐?웹이냐?
앱이냐?웹이냐?앱이냐?웹이냐?
앱이냐?웹이냐?
 
앱이냐?웹이냐?
앱이냐?웹이냐?앱이냐?웹이냐?
앱이냐?웹이냐?
 
Beta News
Beta NewsBeta News
Beta News
 
ClouDoc intro_eng_20161121
ClouDoc intro_eng_20161121ClouDoc intro_eng_20161121
ClouDoc intro_eng_20161121
 
[141]지난 1년간의 웨일 브라우저와 그 미래 (부제: 제품 매니저가 들려주는 생생한 기술/제품 이야기)
[141]지난 1년간의 웨일 브라우저와 그 미래 (부제: 제품 매니저가 들려주는 생생한 기술/제품 이야기)[141]지난 1년간의 웨일 브라우저와 그 미래 (부제: 제품 매니저가 들려주는 생생한 기술/제품 이야기)
[141]지난 1년간의 웨일 브라우저와 그 미래 (부제: 제품 매니저가 들려주는 생생한 기술/제품 이야기)
 
2012, 대한민국 웹 표준, 그 기로에 서다
2012, 대한민국 웹 표준, 그 기로에 서다2012, 대한민국 웹 표준, 그 기로에 서다
2012, 대한민국 웹 표준, 그 기로에 서다
 
H3 2011 반응형 웹디자인,진짜 할 만 한가?_Fi팀_신현석
H3 2011 반응형 웹디자인,진짜 할 만 한가?_Fi팀_신현석H3 2011 반응형 웹디자인,진짜 할 만 한가?_Fi팀_신현석
H3 2011 반응형 웹디자인,진짜 할 만 한가?_Fi팀_신현석
 
H3 2011 반응형 웹디자인, 진짜 할 만 한가?
H3 2011 반응형 웹디자인, 진짜 할 만 한가?H3 2011 반응형 웹디자인, 진짜 할 만 한가?
H3 2011 반응형 웹디자인, 진짜 할 만 한가?
 
mobile platform
mobile platformmobile platform
mobile platform
 
Mobile Platform
Mobile PlatformMobile Platform
Mobile Platform
 
The personalcloud 20100505
The personalcloud 20100505The personalcloud 20100505
The personalcloud 20100505
 
The personal cloud
The personal cloudThe personal cloud
The personal cloud
 
질병관리본부 특강 - 모바일 “고해상도 디스플레이” 시대를 준비하다
질병관리본부 특강 - 모바일 “고해상도 디스플레이”  시대를 준비하다질병관리본부 특강 - 모바일 “고해상도 디스플레이”  시대를 준비하다
질병관리본부 특강 - 모바일 “고해상도 디스플레이” 시대를 준비하다
 
DEC2010 Track C-2 실버라이트로 시작하는 윈도우폰7의 만남
DEC2010 Track C-2 실버라이트로 시작하는 윈도우폰7의 만남DEC2010 Track C-2 실버라이트로 시작하는 윈도우폰7의 만남
DEC2010 Track C-2 실버라이트로 시작하는 윈도우폰7의 만남
 

Recently uploaded

Merge (Kitworks Team Study 이성수 발표자료 240426)
Merge (Kitworks Team Study 이성수 발표자료 240426)Merge (Kitworks Team Study 이성수 발표자료 240426)
Merge (Kitworks Team Study 이성수 발표자료 240426)Wonjun Hwang
 
MOODv2 : Masked Image Modeling for Out-of-Distribution Detection
MOODv2 : Masked Image Modeling for Out-of-Distribution DetectionMOODv2 : Masked Image Modeling for Out-of-Distribution Detection
MOODv2 : Masked Image Modeling for Out-of-Distribution DetectionKim Daeun
 
캐드앤그래픽스 2024년 5월호 목차
캐드앤그래픽스 2024년 5월호 목차캐드앤그래픽스 2024년 5월호 목차
캐드앤그래픽스 2024년 5월호 목차캐드앤그래픽스
 
Console API (Kitworks Team Study 백혜인 발표자료)
Console API (Kitworks Team Study 백혜인 발표자료)Console API (Kitworks Team Study 백혜인 발표자료)
Console API (Kitworks Team Study 백혜인 발표자료)Wonjun Hwang
 
A future that integrates LLMs and LAMs (Symposium)
A future that integrates LLMs and LAMs (Symposium)A future that integrates LLMs and LAMs (Symposium)
A future that integrates LLMs and LAMs (Symposium)Tae Young Lee
 
Continual Active Learning for Efficient Adaptation of Machine LearningModels ...
Continual Active Learning for Efficient Adaptation of Machine LearningModels ...Continual Active Learning for Efficient Adaptation of Machine LearningModels ...
Continual Active Learning for Efficient Adaptation of Machine LearningModels ...Kim Daeun
 

Recently uploaded (6)

Merge (Kitworks Team Study 이성수 발표자료 240426)
Merge (Kitworks Team Study 이성수 발표자료 240426)Merge (Kitworks Team Study 이성수 발표자료 240426)
Merge (Kitworks Team Study 이성수 발표자료 240426)
 
MOODv2 : Masked Image Modeling for Out-of-Distribution Detection
MOODv2 : Masked Image Modeling for Out-of-Distribution DetectionMOODv2 : Masked Image Modeling for Out-of-Distribution Detection
MOODv2 : Masked Image Modeling for Out-of-Distribution Detection
 
캐드앤그래픽스 2024년 5월호 목차
캐드앤그래픽스 2024년 5월호 목차캐드앤그래픽스 2024년 5월호 목차
캐드앤그래픽스 2024년 5월호 목차
 
Console API (Kitworks Team Study 백혜인 발표자료)
Console API (Kitworks Team Study 백혜인 발표자료)Console API (Kitworks Team Study 백혜인 발표자료)
Console API (Kitworks Team Study 백혜인 발표자료)
 
A future that integrates LLMs and LAMs (Symposium)
A future that integrates LLMs and LAMs (Symposium)A future that integrates LLMs and LAMs (Symposium)
A future that integrates LLMs and LAMs (Symposium)
 
Continual Active Learning for Efficient Adaptation of Machine LearningModels ...
Continual Active Learning for Efficient Adaptation of Machine LearningModels ...Continual Active Learning for Efficient Adaptation of Machine LearningModels ...
Continual Active Learning for Efficient Adaptation of Machine LearningModels ...
 

유니버셜 앱의 가능성

  • 1.
  • 2. 이종인 *바람 인터렉티브 Founder *Windows Platform Development MVP * Windows Phone 앱 개발 - - lunelake@outlook.com http://www.facebook.com/BaramInteractive design me
  • 3.
  • 4. 다른 사람과 떠들고 싶다 일상들의 아름다운 순간들을 남기고 주변사람들과 공유하고 싶다 음악을 마음껏 듣고 싶다 맛 집 정보를 얻고 싶다 건강을 관리하고 싶다 빠르게 기록하고 정리하고 싶다 + 놀고 싶다
  • 5. 사람들에게 도움이 되는 무언가를 만들어서 많은 사람들이 쓰게 하고 싶다+
  • 6. +
  • 7.
  • 8. 서비스를 많은 사람들이 쓰게 하는 방법
  • 9. 더 이상 집에 컴퓨터 한대 놓여 있는 게 아닌 세상
  • 10. 다양한 디바이스에서도 끊임 없는 경험의 연결
  • 12. Web 서비스 업데이트 및 에러 발생 시
  • 13.
  • 15. Windows 10에서의 앱 사용환경의 변화
  • 16. Windows 10으로 1년 내 업그레이드 시 무료
  • 17.
  • 18. 데스크탑, 태블릿, 폰을 아우르는 서비스를 한 프로젝트에서 (Shared project, PCL)
  • 21. 화면 크기에 대응하는 UI 7” 6” 5” 4.5” Infinite virtual canvas x y PortraitLandscape
  • 22. 디바이스의 크기와 환경에 따라 달라지는 유저들의 요구와 그로 인해 파편화된 경험들 합치기
  • 24. Grid.Row xGrid.Column <Grid> <Grid.ColumnDefinitions> <ColumnDefinition Width="100" /> <ColumnDefinition Width=“Auto" /> <ColumnDefinition Width="100" /> </Grid.ColumnDefinitions> <Rectangle Grid.Column=“0" Grid.ColumnSpan=“2" /> </Grid> <Grid> <Grid.RowDefinitions> <RowDefinition Height=“100" /> <RowDefinition Height=“Auto" /> <RowDefinition Height=“100" /> </Grid. RowDefinitions> <Rectangle Grid.Row=“1" /> </Grid> 0 1 2 0 1 2
  • 25. Grid 화면크기에 대응 x <Grid> <Grid.ColumnDefinitions> <ColumnDefinition Width=“50" /> <ColumnDefinition Width=“1*" /> <ColumnDefinition Width="1*" /> <ColumnDefinition Width=“50" /> </Grid.ColumnDefinitions> </Grid> 50 501* 1* 50 501* 1* 50 501* 1*
  • 27. Viewbox x <Grid Background="Black"> <GridView Margin="100,100,0,0"> <Rectangle Fill="Red" Height="200" Width="200" /> <Rectangle Fill="Red" Height="200" Width="200" /> <Rectangle Fill="Red" Height="200" Width="200" /> <Rectangle Fill="Red" Height="200" Width="200" /> <Rectangle Fill="Red" Height="200" Width="200" /> </GridView> </Grid> <Grid Background="Black"> <Viewbox HorizontalAlignment="Left"> <GridView Margin="100,100,0,0" Height="768" > <Rectangle Fill="Red" Height="200" Width="200" /> <Rectangle Fill="Red" Height="200" Width="200" /> <Rectangle Fill="Red" Height="200" Width="200" /> <Rectangle Fill="Red" Height="200" Width="200" /> <Rectangle Fill="Red" Height="200" Width="200" /> </GridView> </Viewbox> </Grid> Element 비율 따라 크기 조정 Element 크기 조정
  • 28. 윈도우 사이즈가 변했을 때 x protected override void OnNavigatedTo(NavigationEventArgs e) { this.navigationHelper.OnNavigatedTo(e); Window.Current.SizeChanged += Current_SizeChanged; } protected override void OnNavigatedFrom(NavigationEventArgs e) { this.navigationHelper.OnNavigatedFrom(e); Window.Current.SizeChanged -= Current_SizeChanged; } /// <summary> /// 윈도우의 사이즈가 변했을 때 이벤트 /// </summary> public void Current_SizeChanged(object sender, Windows.UI.Core.WindowSizeChangedEventArgs e) { double windowWidth = e.Size.Width; double windowHeight = e.Size.Height; //로직 }
  • 29.
  • 30.
  • 32. 윈도우 기기간 데이터 동기화 즉결성 보장X) 비용 지출X 비용 지출O
  • 33. Roaming storage를 통한 데이터 동기화 StorageFolder roamingFolder = ApplicationData.Current.RoamingFolder; public async void SaveText(string saveText) { StorageFile sampleFile = await roamingFolder.CreateFileAsync("dataFile.txt", CreationCollisionOption.ReplaceExisting); await FileIO.WriteTextAsync(sampleFile, saveText); } ApplicationDataContainer roamingSettings = ApplicationData.Current.RoamingSettings; public void SaveSetting() { roamingSettings.Values["exampleSetting"] = "Hello World"; roamingSettings.Values["HighPriority"] = "65"; } 설정 저장 텍스트 저장
  • 34. OnlineIdAuthenticator를 통한 Onedrive 동기화 public class WindowsAccountAuthenticator { OnlineIdAuthenticator authenticator; public WindowsAccountAuthenticator() { authenticator = new OnlineIdAuthenticator(); } /// <summary> /// 마이크로소프트 계정 로그인 및 인증 /// </summary> public async Task SignIn() { var targetArray = new List<OnlineIdServiceTicketRequest>(); targetArray.Add(new OnlineIdServiceTicketRequest("wl.signin", "DELEGATION")); var result = await authenticator.AuthenticateUserAsync(targetArray, CredentialPromptType.PromptIfNeeded); string AccessToken = result.Tickets[0].Value; } }
  • 36. Credential Locker MSA void SaveCredential(string username, string password) { PasswordVault vault = new PasswordVault(); PasswordCredential cred = new PasswordCredential("MyAppResource", username, password); vault.Add(cred); } IReadOnlyList<PasswordCredential> RetrieveCredential(string resource) { PasswordVault vault = new PasswordVault(); return vault.FindAllByResource(resource); }
  • 37. 애저 모바일 서비스 Custom API 스케줄러 푸시 저장소 (용량 제한) C# Javascript
  • 38. Custom API Ex)TimeChecker 요청 현재 시간 체크 현재시간 리턴 https://{ServiceName}.azure-mobile.net/api/{API Name} Rest API C# - SDK DateTimeOffset result = await App.{MobileServiceClientName}.InvokeApiAsync<DateTimeOffset> (“{API Name}", HttpMethod.Get, null); "2015-01-30T13:26:11.829Z" 리턴
  • 39. Push Notification Azure Mobile Service Push wns apns gcm // windows var toast = @"<toast><visual> <binding template=""ToastText01""> <text id=""1"">Hello</text></binding></visual></toast>"; await Notifications.Instance.Hub.SendWindowsNativeNotificationAsync(toast,userTag); // apns var alert = "{"aps":{"alert":"Hello"}}"; await Notifications.Instance.Hub.SendAppleNativeNotificationAsync(alert,userTag); // gcm var notif = "{ "data" : {"msg":"Hello"}}"; await Notifications.Instance.Hub.SendGcmNativeNotificationAsync(notif,userTag);
  • 40. 디바이스간 데이터 동기화 시나리오 Azure Mobile Service Push notification 동기화 앱 켜질시 동기화
  • 41.
  • 42. 서비스에서의 웹 서비스 활용 Azure Mobile Service Azure Web Service
  • 43.
  • 44.
  • 45. Design Me에서의 PCL 사용 PCL Azure Web Service Azure Mobile Service (Shared code, logic, datamodel.. Etc) Universal Windows App
  • 46. Data model 공유 PCL Universal App Mobile Service Controller public class Request { public string request { get; set; } } public class Result { public string result { get; set; } } Controller public async Task<HttpResponseMessage> Post(Request request) { Result result = new Result(); //처리 return Request.CreateResponse (HttpStatusCode.OK, result); } Request Request request = new Request() Result result = await App.{ClientName} .InvokeApiAsync<Request, Result> (“APIName", request);
  • 47.
  • 48. 플랫폼간 긴밀하게 연결되는 서비스 C# PCL Universal Windows App A z u r e
  • 50. Web Azure와 Xamarin, PCL을 활용한 개발 프로세스 Windows