忘備録

日々の調べ物をまとめる。アウトプットする。基本自分用。

【Objective-C】NSIntegerがあって、NSDoubleがないわけ

objective c - Do NSDouble, NSFloat, or other types than NSInteger exist? - Stack Overflow NSInteger exists because the int type varies in size between 32-bit and 64-bit systems. float and double don't vary in size the same way, so there's …

【Objective-C】数値を文字列に変換

NSString + (instancetype)stringWithFormat:(NSString *)format を使う double number = 3.14; NSString *numberString = [NSString stringWithFormat:@"%f", number]; 参考:NSString Class Reference

【Objective-C】プロパティ名の制約

以下のようなコードを書いたところ。。。 hogehoge.h @property NSString *newHoge; Xcodeから以下のようにお叱りが。。。 Property follows Cocoa naming convention for returning 'owned' objects んで、調べてみた objective c - Semantic Issue: Proper…

ハードリンクとシンボリックリンク違い

ハードリンク iノードで参照 同一ファイルシステム内に限られる ファイルのみ(と思っておいた方がいい) 元のファイルを移動しても問題ない 元のファイルを削除しても消えない シンボリックリンクパスで参照 パス 別のファイルシステムでもいける ディレクト…

Android Studio(Intellij)のプロジェクトに含まれる「.idea」ディレクトリ

「.idea?なんぞこいつは?」となったので調べてみた [Intellij IDEAヘルプ 日本語訳] プロジェクト設定とIDE設定 - Qiita プロジェクト設定はそれぞれのプロジェクトごとにxmlファイルの集合として.ideaディレクトリの下に保存される。 らしいです(雑)

Xcodeでsvnにアクセスするとエラー

以下のエラーが発生 svn: E175013: Unable to connect to a repository at URL 'http://xxx.xxx.xxx.xxx/hoge' svn: E175013: Access to 'http://xxx.xxx.xxx.xxx/hoge' forbidden 環境 OS: OS X 10.10.5 Xcode: 7.0.1 原因:クライアントとサーバとでSVNの…

table内のリンクをセル全体に広げる方法

方法: aタグのstyleにdisplay: block; width: 100%; height: 100%を設定する ソース <html lang="ja"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <style type="text/css"> table, td, th { border: 1px red solid; } a:hover { background-color:#ffcccc; } </style> </head> <body> …</body></html>

Android 実機デバッグ はまったこと

adbにて実機にアクセス時に「error: more than one device/emulator」 環境: OS: Mac OS X 10.10.5 Androidバージョン: 4.4.4 端末: SO-02G 原因:接続デバイスが複数ある状態で接続先の指定をしていない 対応:接続先を指定する # エラー。。。 $ adb shel…