0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

gitwatch > sinceYearMonth / fromYearMonth

Last updated at Posted at 2015-06-28

ある年月以降の処理をするクラスを作っていて、その変数名をどうしようか考えていた。

githubで検索した所

  • sinceMonthやsinceYear : code例がいくつかある
  • sinceYearMonth : code例なし
  • fromYearMonth : code例がいくつかある

sinceとfromの英語的な違いは以下が興味深かった
http://lib21.blog96.fc2.com/blog-entry-2010.html

from は「起点」を示す (starting at a particular time and continuing)
since は「過去の起点から現在まで」を示す (from the past until the present time)

取得済みの過去データに対して、ある年月以降のデータだけ処理したい場合、since があっているかも。

一方で、ある年月以降から今後も処理続けるような場合は from があっているように思う。

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?