{"id":129738,"date":"2024-03-25T11:52:40","date_gmt":"2024-03-25T02:52:40","guid":{"rendered":"https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/"},"modified":"2024-03-27T22:09:25","modified_gmt":"2024-03-27T13:09:25","slug":"ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0","status":"publish","type":"post","link":"https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/","title":{"rendered":"iOS \u306e presentViewController \u306e\u8a73\u7d30"},"content":{"rendered":"<p>iOS \u306e presentViewController \u306f\u3001\u65b0\u3057\u3044\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u3092\u8868\u793a\u3059\u308b\u305f\u3081\u306e\u30e1\u30bd\u30c3\u30c9\u3067\u3059\u3002UIViewController \u30af\u30e9\u30b9\u306e\u30e1\u30bd\u30c3\u30c9\u3067\u3042\u308a\u3001\u73fe\u5728\u306e\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u306e\u30c8\u30c3\u30d7\u306b\u5225\u306e\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u3092\u8868\u793a\u3059\u308b\u305f\u3081\u306b\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n<p>presentViewController \u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3059\u308b\u969b\u306b\u306f\u3001\u8868\u793a\u3059\u308b\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u30d1\u30e9\u30e1\u30fc\u30bf\u3068\u3057\u3066\u6e21\u3059\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u30e1\u30bd\u30c3\u30c9\u306e\u69cb\u6587\u3092\u4ee5\u4e0b\u306b\u793a\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>func presentViewController(_ viewControllerToPresent: UIViewController, animated flag: Bool, completion: (() -&gt; Void)? = nil)\r\n<\/code><\/pre>\n<ol>\n<li>\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u3092\u8868\u793a\u7528<\/li>\n<li>flag\uff1a\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u306e\u8868\u793a\u6642\u306b\u3001\u30a2\u30cb\u30e1\u30fc\u30b7\u30e7\u30f3\u3092\u4f7f\u7528\u3059\u308b\u304b\u3069\u3046\u304b\u306e\u30d6\u30fc\u30ea\u30a2\u30f3<\/li>\n<li>\u5b8c\u4e86\uff1a\u8868\u793a\u5b8c\u6bd5\u540e\u7684\u5904\u7406\u7684\u4efb\u610f\u95ed\u5305\u9009\u9879\u3002<\/li>\n<\/ol>\n<p>presentViewController\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3059\u308b\u3068\u3001\u3053\u308c\u304b\u3089\u8868\u793a\u3059\u308b\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u304c\u3001\u73fe\u5728\u306e\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u306e\u4e0a\u306b\u914d\u7f6e\u3055\u308c\u3001\u73fe\u5728\u306e\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u306f\u96a0\u308c\u307e\u3059\u3002<\/p>\n<p>presentViewController\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3059\u308b\u30b5\u30f3\u30d7\u30eb\u30b3\u30fc\u30c9\u3092\u4ee5\u4e0b\u306b\u793a\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code><span class=\"hljs-keyword\">let<\/span> secondViewController <span class=\"hljs-operator\">=<\/span> <span class=\"hljs-type\">SecondViewController<\/span>() <span class=\"hljs-comment\">\/\/ \u521b\u5efa\u8981\u5448\u73b0\u7684\u89c6\u56fe\u63a7\u5236\u5668\u5bf9\u8c61<\/span>\r\n<span class=\"hljs-keyword\">self<\/span>.presentViewController(secondViewController, animated: <span class=\"hljs-literal\">true<\/span>, completion: <span class=\"hljs-literal\">nil<\/span>) <span class=\"hljs-comment\">\/\/ \u4f7f\u7528presentViewController\u65b9\u6cd5\u5448\u73b0\u89c6\u56fe\u63a7\u5236\u5668<\/span>\r\n<\/code><\/pre>\n<p>\u3053\u306e\u4f8b\u3067\u306f\u3001SecondViewController\u3068\u3044\u3046\u540d\u524d\u306e\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u4f5c\u6210\u3057\u3001presentViewController\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3057\u3066\u3001\u73fe\u884c\u306e\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u306b\u8868\u793a\u3057\u307e\u3059\u3002<\/p>\n<p>presentViewController\u30e1\u30bd\u30c3\u30c9\u3067\u8868\u793a\u3057\u305f\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u306f\u3001dismissViewControllerAnimated\u30e1\u30bd\u30c3\u30c9\u3092\u547c\u3073\u51fa\u3059\u3053\u3068\u3067\u9589\u3058\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002dismissViewControllerAnimated\u30e1\u30bd\u30c3\u30c9\u306e\u547c\u3073\u51fa\u3057\u4f8b\u306f\u4e0b\u8a18\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code><span class=\"hljs-keyword\">self<\/span>.dismissViewControllerAnimated(<span class=\"hljs-literal\">true<\/span>, completion: <span class=\"hljs-literal\">nil<\/span>) <span class=\"hljs-comment\">\/\/ \u5173\u95ed\/\u9690\u85cf\u5448\u73b0\u7684\u89c6\u56fe\u63a7\u5236\u5668<\/span>\r\n<\/code><\/pre>\n<p>\u3053\u306e\u4f8b\u3067\u306fpresentViewController\u30e1\u30bd\u30c3\u30c9\u3067\u8868\u793a\u3057\u305f\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u3092dismissViewControllerAnimated\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u3063\u3066\u7834\u68c4\u30fb\u975e\u8868\u793a\u306b\u3057\u3066\u307e\u3059\u3002<\/p>\n<p>\u307e\u3068\u3081\u308b\u3068<\/p>\n<p>presentViewController\u306f\u3001iOS\u3067\u65b0\u3057\u3044\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u3092\u8868\u793a\u3059\u308b\u305f\u3081\u306b\u4f7f\u7528\u3059\u308b\u30e1\u30bd\u30c3\u30c9\u3067\u3001\u8868\u793a\u3059\u308b\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u3092\u73fe\u5728\u306e\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u306e\u4e0a\u306b\u91cd\u306d\u3066\u73fe\u5728\u306e\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u3092\u8986\u3044\u307e\u3059\u3002presentViewController\u30e1\u30bd\u30c3\u30c9\u3067\u8868\u793a\u3057\u305f\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u3092\u9589\u3058\u308b\uff08\u975e\u8868\u793a\u306b\u3059\u308b\uff09\u306b\u306f\u3001dismissViewControllerAnimated\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>iOS \u306e presentViewController \u306f\u3001\u65b0\u3057\u3044\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u3092\u8868\u793a\u3059\u308b\u305f\u3081\u306e\u30e1\u30bd\u30c3\u30c9\u3067\u3059\u3002UIViewController \u30af\u30e9\u30b9\u306e\u30e1\u30bd\u30c3\u30c9\u3067\u3042\u308a\u3001\u73fe\u5728\u306e\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u306e\u30c8\u30c3\u30d7\u306b\u5225\u306e\u30d3\u30e5\u30fc\u30b3\u30f3 [&hellip;]<\/p>\n","protected":false},"author":5,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-129738","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v21.5 (Yoast SEO v21.5) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>iOS \u306e presentViewController \u306e\u8a73\u7d30 - Blog - Silicon Cloud<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.silicloud.com\/ja\/blog\/ios-\u306e-presentviewcontroller-\u306e\u8a73\u7d30\/\" \/>\n<meta property=\"og:locale\" content=\"ja_JP\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"iOS \u306e presentViewController \u306e\u8a73\u7d30\" \/>\n<meta property=\"og:description\" content=\"iOS \u306e presentViewController \u306f\u3001\u65b0\u3057\u3044\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u3092\u8868\u793a\u3059\u308b\u305f\u3081\u306e\u30e1\u30bd\u30c3\u30c9\u3067\u3059\u3002UIViewController \u30af\u30e9\u30b9\u306e\u30e1\u30bd\u30c3\u30c9\u3067\u3042\u308a\u3001\u73fe\u5728\u306e\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u306e\u30c8\u30c3\u30d7\u306b\u5225\u306e\u30d3\u30e5\u30fc\u30b3\u30f3 [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.silicloud.com\/ja\/blog\/ios-\u306e-presentviewcontroller-\u306e\u8a73\u7d30\/\" \/>\n<meta property=\"og:site_name\" content=\"Blog - Silicon Cloud\" \/>\n<meta property=\"article:published_time\" content=\"2024-03-25T02:52:40+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-03-27T13:09:25+00:00\" \/>\n<meta name=\"author\" content=\"\u685c, \u6625\u6a39\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u57f7\u7b46\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"\u685c, \u6625\u6a39\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/\",\"url\":\"https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/\",\"name\":\"iOS \u306e presentViewController \u306e\u8a73\u7d30 - Blog - Silicon Cloud\",\"isPartOf\":{\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#website\"},\"datePublished\":\"2024-03-25T02:52:40+00:00\",\"dateModified\":\"2024-03-27T13:09:25+00:00\",\"author\":{\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/ff22288af1a5455571aff7586b0fb341\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/#breadcrumb\"},\"inLanguage\":\"ja\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.silicloud.com\/ja\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"iOS \u306e presentViewController \u306e\u8a73\u7d30\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#website\",\"url\":\"https:\/\/www.silicloud.com\/ja\/blog\/\",\"name\":\"Blog - Silicon Cloud\",\"description\":\"\",\"inLanguage\":\"ja\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/ff22288af1a5455571aff7586b0fb341\",\"name\":\"\u685c, \u6625\u6a39\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/cee48863f3d4fd7fef222498f3e71b82312aee42b7257a2dbde56394ca4e19de?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/cee48863f3d4fd7fef222498f3e71b82312aee42b7257a2dbde56394ca4e19de?s=96&d=mm&r=g\",\"caption\":\"\u685c, \u6625\u6a39\"},\"url\":\"https:\/\/www.silicloud.com\/ja\/blog\/author\/sakuraharuki\/\"},{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/#local-main-organization-logo\",\"url\":\"\",\"contentUrl\":\"\",\"caption\":\"Blog - Silicon Cloud\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"iOS \u306e presentViewController \u306e\u8a73\u7d30 - Blog - Silicon Cloud","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.silicloud.com\/ja\/blog\/ios-\u306e-presentviewcontroller-\u306e\u8a73\u7d30\/","og_locale":"ja_JP","og_type":"article","og_title":"iOS \u306e presentViewController \u306e\u8a73\u7d30","og_description":"iOS \u306e presentViewController \u306f\u3001\u65b0\u3057\u3044\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u3092\u8868\u793a\u3059\u308b\u305f\u3081\u306e\u30e1\u30bd\u30c3\u30c9\u3067\u3059\u3002UIViewController \u30af\u30e9\u30b9\u306e\u30e1\u30bd\u30c3\u30c9\u3067\u3042\u308a\u3001\u73fe\u5728\u306e\u30d3\u30e5\u30fc\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u306e\u30c8\u30c3\u30d7\u306b\u5225\u306e\u30d3\u30e5\u30fc\u30b3\u30f3 [&hellip;]","og_url":"https:\/\/www.silicloud.com\/ja\/blog\/ios-\u306e-presentviewcontroller-\u306e\u8a73\u7d30\/","og_site_name":"Blog - Silicon Cloud","article_published_time":"2024-03-25T02:52:40+00:00","article_modified_time":"2024-03-27T13:09:25+00:00","author":"\u685c, \u6625\u6a39","twitter_card":"summary_large_image","twitter_misc":{"\u57f7\u7b46\u8005":"\u685c, \u6625\u6a39"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/","url":"https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/","name":"iOS \u306e presentViewController \u306e\u8a73\u7d30 - Blog - Silicon Cloud","isPartOf":{"@id":"https:\/\/www.silicloud.com\/ja\/blog\/#website"},"datePublished":"2024-03-25T02:52:40+00:00","dateModified":"2024-03-27T13:09:25+00:00","author":{"@id":"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/ff22288af1a5455571aff7586b0fb341"},"breadcrumb":{"@id":"https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/#breadcrumb"},"inLanguage":"ja","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.silicloud.com\/ja\/blog\/"},{"@type":"ListItem","position":2,"name":"iOS \u306e presentViewController \u306e\u8a73\u7d30"}]},{"@type":"WebSite","@id":"https:\/\/www.silicloud.com\/ja\/blog\/#website","url":"https:\/\/www.silicloud.com\/ja\/blog\/","name":"Blog - Silicon Cloud","description":"","inLanguage":"ja"},{"@type":"Person","@id":"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/ff22288af1a5455571aff7586b0fb341","name":"\u685c, \u6625\u6a39","image":{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/cee48863f3d4fd7fef222498f3e71b82312aee42b7257a2dbde56394ca4e19de?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/cee48863f3d4fd7fef222498f3e71b82312aee42b7257a2dbde56394ca4e19de?s=96&d=mm&r=g","caption":"\u685c, \u6625\u6a39"},"url":"https:\/\/www.silicloud.com\/ja\/blog\/author\/sakuraharuki\/"},{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/www.silicloud.com\/ja\/blog\/ios-%e3%81%ae-presentviewcontroller-%e3%81%ae%e8%a9%b3%e7%b4%b0\/#local-main-organization-logo","url":"","contentUrl":"","caption":"Blog - Silicon Cloud"}]}},"_links":{"self":[{"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/posts\/129738","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/comments?post=129738"}],"version-history":[{"count":2,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/posts\/129738\/revisions"}],"predecessor-version":[{"id":195848,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/posts\/129738\/revisions\/195848"}],"wp:attachment":[{"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/media?parent=129738"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/categories?post=129738"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/tags?post=129738"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}