pst

0

votes
0

answer
3

views

Google Cloud API client - How to enable specific API programmatically?

I am trying to automate few steps for a google cloud project. I will be receiving project ID and service account credentials (json) as input to my program. I would like to enable few APIs like 'Cloud Machine Learning API' or 'Resource Management API' for this service account programmatically. [Co...
PST
1

votes
1

answer
55

views

Does OpenMP hints bypass the vectorisation legality check in llvm

I am currently looking into how '#pragma omp for simd' is actually recognised in llvm. To my knowledge, clang will parse it and set metadata in IR to indicate this force-vectorisation hint and later optimisation passes would read it and vectorise the marked loop. Therefore, the loop should be vector...
PST
1

votes
1

answer
3.7k

views

Jersey - What is the difference in injecting UriInfo as class instance variable and injecting it as method parameter?

I came across injecting UriInfo in two ways - @Path('/users/') public class UsersResource { @Context UriInfo uriInfo; ... @GET @Produces('application/json') public JSONArray getUsersAsJsonArray() { } Another way is - @Path('/users/') public class UsersResource { ... @GET @Produces('application/jso...
PST
1

votes
1

answer
427

views

What is the best way to support nested object model in java?

I need to support UI client which has nested components. I have come up with below object model - public class SomeUserInterface { String name; List components; } public class Component { List components; } Here, SomeUserInterface will have multiple Components and each Component may have nes...
PST
1

votes
1

answer
2.7k

views

javax.ws.rs.core.Response.readEntity(Pet.class) results in Exception MessageBodyProviderNotFoundException

I am writing a REST client using jersey. My REST api uses custom message body writer. I am getting correct output using POSTMAN but when I tried to write a client, I am getting an exception. @ApplicationPath('webapi') public class MyApplication extends Application { } import javax.ws.rs.GET; impor...
PST
1

votes
1

answer
66

views

List wild repos I have access to with gitolite

I have installed gitolite and switched on wild repos. With a rule for repo u/CREATOR/\w.* I can indeed create repos as I expect. But how can I list them to see which ones already exist? With ssh [email protected] info I only see the 'normal' repos and a 'C R W' line for all the wild repos. I don't...
pst
1

votes
1

answer
39

views

Global TAction with shorcut key BkSp

I have TAction with ShortCut key set to BkSp (backspace). I'm trying implementing Back button like in web browser so I need TAction is called in any control except Edit controls (TMemo, TEdit etc.). All works as expected, but Backspace key is not sent to Edit controls (so user can't delete char). O...
PSt
1

votes
1

answer
186

views

Where can I find the llvm -stats information

I am running the command line opt test.bc -loop-vectorize -o test2.bc -stats to check the statistics collected by the LLVM loop vectorize pass. However, after running the command, I only get the test2.bc without getting any stats printed. May I know where should I look for these stats? Thanks in ad...
PST
1

votes
2

answer
8k

views

Accessing a session in jQuery

Can I set a session variable in jQuery? I need to store some data in the session from jQuery and I also want to retrieve that data via jQuery. Is there anything like $.getSession.set('var','value');
pst
1

votes
2

answer
99

views

Strange gcc6.1 -O2 compiling behaviour

I am compiling the same benchmark using gcc -O2 -march=native flags. However, Interesting thing is when I look at the objdump, it actually produce some instructions like vxorpd etc, which I think should only appear when ftree-vectorize is enabled (and O2 should not enable this by default?) If I add...
PST
5

votes
1

answer
1.5k

views

VS2012 Server Explorer - Cannot Access Windows Azure Storage

I have VS2012 Ultimate SP3 and a Windows Azure account. I have published an MVC 3 application, using an Azure SQL Server DB without problems. I have installed the Azure SDK (v2.1) and can access the database and web site through the Server Explorer. I have now created an Azure Storage Container ho...
Derek Davidson PST
2

votes
3

answer
19.9k

views

Arrange elements horizontally or vertically wrapped in a div

I am trying to write generic css selectors which will arrange any elements wrapped inside a div as vertically or horizontally. I do not have control on the elements which will be placed inside outer div. For example : In below snippet, div (id=one), div(id=two) and button (id = three) should be di...
PST
5

votes
0

answer
50

views

How do I find all available locales in Python

How can I (on a GNU/Linux system) find all available locales to use with the module locale? The only thing I find that is close in the the module is the dictionary locale_alias with aliases for locales. That is sometimes mentioned as where to look what locales you have, but it doesn't contain all al...
pst
5

votes
7

answer
334

views

Java private method signature clarity and better practice [closed]

I received the code review comment for below code snippet - public void doWork(String a, Integer b) { .. .. SomeService service = getService(); for (Integer i : numbers) { doMoreWork(a, b, service); } } private void doMoreWork(String a, Integer b, SomeService service) { ... ... ... service.doingMor...
PST
18

votes
6

answer
46.5k

views

Android SDK Manager is not showing ARM EABI v7a System Image option

I am trying to setup environment to build application on Android platform. I have followed steps from http://developer.android.com/sdk/installing.html and did install SDK and Eclispe ADT Plugins. While running Hello World application, I received an error : SDK Manager] Unable to find a 'userdata....
PST