Questions

What's the difference between Instant and LocalDateTime?

I know that: - - Still in the end IMO both can be taken as types for most application use cases. As an example: currently, I am running a batch job where I need to calculate the next run based on dat...

20 Sep at 07:30

What is the precise meaning of "ours" and "theirs" in git?

This might sound like too basic of a question, but I have searched for answers and I am more confused now than before. What does "ours" and "theirs" mean in git when merging my branch into my other b...

29 Jul at 09:11

Meaning of numbers in "col-md-4"," col-xs-1", "col-lg-2" in Bootstrap

I am confused with the grid system in the new Bootstrap, particularly these classes: ``` col-lg-* col-md-* col-xs-* ``` (where * represents some number). Can anyone please explain the following: ...

How to determine SSL cert expiration date from a PEM encoded certificate?

If I have the actual file and a Bash shell in Mac or Linux, how can I query the cert file for when it will expire? Not a web site, but actually the certificate file itself, assuming I have the csr, k...

11 Dec at 11:28

Convert file: Uri to File in Android

What is the easiest way to convert from an [android.net.Uri](https://developer.android.com/reference/android/net/Uri) object which holds a `file:` type to a [java.io.File](https://developer.android.co...

22 Nov at 22:14

PostgreSQL: Modify OWNER on all tables simultaneously in PostgreSQL

How do I modify the owner of all tables in a PostgreSQL database? I tried `ALTER TABLE * OWNER TO new_owner` but it doesn't support the asterisk syntax.

23 Jul at 13:51

How do you get git to always pull from a specific branch?

I'm not a git master, but I have been working with it for some time now, with several different projects. In each project, I always `git clone [repository]` and from that point, can always `git pull`...

18 Mar at 19:18

Invariant Violation: Objects are not valid as a React child

In my component's render function I have: ``` render() { const items = ['EN', 'IT', 'FR', 'GR', 'RU'].map((item) => { return (<li onClick={this.onItemClick.bind(this, item)} key={item}>{ite...

16 Nov at 15:55

How to get the list of all installed color schemes in Vim?

Is there a way to get a list of all installed color schemes in Vim? That would make very easy to select one without looking at the `.vim` directory.

5 Oct at 00:44

How to detect DIV's dimension changed?

I've the following sample html, there is a DIV which has 100% width. It contains some elements. While performing windows re-sizing, the inner elements may be re-positioned, and the dimension of the di...

27 Jun at 12:13

Why do we use volatile keyword?

> [Why does volatile exist?](https://stackoverflow.com/questions/72552/) I have never used it but I wonder why people use it? What does it exactly do? I searched the forum, I found it only C# or Jav...

14 Jan at 12:41

How do I truncate a .NET string?

I would like to truncate a string such that its length is not longer than a given value. I am writing to a database table and want to ensure that the values I write meet the constraint of the column'...

17 Dec at 00:40

What is the best data type to use for money in C#?

What is the best data type to use for money in C#?

14 Oct at 21:17

Create a Date with a set timezone without using a string representation

I have a web page with three dropdowns for day, month and year. If I use the JavaScript `Date` constructor that takes numbers, then I get a `Date` object for my current timezone: ``` new Date(xiYear,...

10 Sep at 09:17

Colspan all columns

How can I specify a `td` tag should span all columns (when the exact amount of columns in the table will be variable/difficult to determine when the HTML is being rendered)? [w3schools](http://www.w3s...

16 Sep at 13:57

How can I pad a String in Java?

Is there some easy way to pad Strings in Java? Seems like something that should be in some StringUtil-like API, but I can't find anything that does this.

21 Sep at 17:20

When do you use Java's @Override annotation and why?

What are the best practices for using Java's `@Override` annotation and why? It seems like it would be overkill to mark every single overridden method with the `@Override` annotation. Are there ...

9 Nov at 00:12

Difference between EXISTS and IN in SQL?

What is the difference between the `EXISTS` and `IN` clause in SQL? When should we use `EXISTS`, and when should we use `IN`?

5 Feb at 15:58

Capture iOS Simulator video for App Preview

Okay, so we can now submit video previews of our apps on the App Store. According to Apple we should do so with an iOS8 device and `OSX 10.10.` The problem is you have to have all the different device...

How to link to a specific line number on GitHub

I know I can link to a specific line number on a file on a GitHub repository (I'm sure I've seen this before)... How can I do this?

27 Oct at 20:6

Can you run GUI applications in a Linux Docker container?

How can you run GUI applications in a Linux [Docker](http://www.docker.io) container? Are there any images that set up `vncserver` or something so that you can - for example - add an extra speedbump s...

3 Jun at 18:16

ng-repeat :filter by single field

I have an array of products that I'm repeating over using ng-repeat and am using ``` <div ng-repeat="product in products | filter:by_colour"> ``` to filter these products by colour. The filter is ...

What are copy elision and return value optimization?

What is copy elision? What is (named) return value optimization? What do they imply? In what situations can they occur? What are limitations? - [the introduction](https://stackoverflow.com/a/1295312...

Android: How to handle right to left swipe gestures

I want my app to recognize when a user swipes from right to left on the phone screen. How to do this?

25 Jul at 12:40

The difference between sys.stdout.write and print?

Are there situations in which `sys.stdout.write()` is preferable to `print`? ( better performance; code that makes more sense)

17 Nov at 16:55