Questions tagged [creation]

Do not use. Too vague to be of any possible significance.

Do not use. Too vague to be of any possible significance. Tag should be removed.

481 questions
3
votes
2 answers

jQuery: How to create element then wrap this around another existing element?

So I know how to use .wrap, .wrapInner and .wrapAll but I am wondering how to use the quick creation syntax introduced in jQuery 1.4 and the wrap function together. Basically I want to be able to use var targetUl = $(this), // would be populated by…
Jannis
  • 17,025
  • 18
  • 62
  • 75
3
votes
2 answers

Nested Dictionaries in Python, with implicit creation of non-existing intermediate containers?

I want to create a polymorphic structure that can be created on the fly with minimum typing effort and be very readable. For example: a.b = 1 a.c.d = 2 a.c.e = 3 a.f.g.a.b.c.d = cucu a.aaa = bau I do not want to create an intermediate container…
RumburaK
  • 1,985
  • 1
  • 21
  • 30
3
votes
4 answers

Java pass two object to each others in one step

I have following main class and main method: public class Main { Peter peter = new Peter(this); Tom tom = new Tom(this); public static void main(String[] args) { Main main = new Main(); System.out.println(main.peter.tom); …
Stefan B
  • 541
  • 2
  • 6
  • 13
3
votes
2 answers

How to create Access database from a script

I would like to create an Access database from a script. Ideally, I would love something similar to the way SQL scripts can be used to create a SQL database. Is this possible at all? Is there anything that would leverage the SQL scripts I already…
Jeremy
  • 3,221
  • 7
  • 27
  • 31
3
votes
1 answer

Kubernetes: kube-dns Service Creation

After writing a skydns-svc.yml file with the IP 192.168.3.10 I recieve the following error: Error: The Service "kube-dns" is invalid:spec.clusterIP: Invalid value: "192.168.3.10": provided IP is not in the valid range skydns-svc.yml apiVersion:…
emarel
  • 371
  • 7
  • 30
3
votes
1 answer

Creation of AMI image, make public through boto

I can't figure out through the botot docs and google search to create an ami image and make it public from the beginning. I can create an ami image, but it is always private. I can only make public afterward through the AWS panel. This is my…
Gary Leong
  • 199
  • 1
  • 2
  • 12
3
votes
1 answer

F# 2D Array alternate creation

I am using the Array2D module in f# and want to create a sudoku game board (a 9x9 array) using it. Right now I have something that works and that looks like this: let createInitialArray = [| [|for x in 1 .. 9 -> createSquare x 1 |]; …
3
votes
4 answers

Extra variable or object creation -- what is better in PHP?

What is better / faster / more efficient in PHP? Using extra variable: $dateStep = new DateInterval('P1D'); for($di = 0; $di <= $dateInterval; ++$di) { $theDate = ($di > 0) ? $startDate->add($dateStep) : $startDate; ... } Or creating…
trejder
  • 17,148
  • 27
  • 124
  • 216
3
votes
2 answers

objective c dynamic object creation

Quick question for you. I want to be able to create an instance of an object. The object type is based of a string. In php you can just replace the class name with a string, but I doubt it is that easy in Objective c. NSString * className; id…
Dark Templer
  • 277
  • 5
  • 10
3
votes
1 answer

Incorrect creating date object in javascript via "new Date()" in Chrome

The problem manifests irregularly and only occurs in Chrome. During the creation of the date object in JavaScript via new Date("..some date time string.."), it occasionally returns the date incorrectly as 6 Sep 2013 12:28:48 GMT+0300 (FLE Daylight…
Andrey Zhminka
  • 243
  • 4
  • 16
3
votes
2 answers

Adding link to json object in android

JSONArray albumarray=new JSONArray(); JSONObject imgobj=new JSONObject(); imgobj.put("thumb", filepath.get(i)); imgobj.put("main", filepath.get(i)); albumarray.put(imgobj); JSONObject albumjson=new JSONObject(); …
Pramod J George
  • 1,723
  • 12
  • 24
3
votes
2 answers

Router, model, or view, which one is the initiator

I am trying to be as lazy loading as possible, But, I am puzzle on how to start, here is my "sequenced comprehension": Objective: Create a contacts page with contacts existing on the server Step1.0: To use the router: the
must…
Mathias-Dev
  • 69
  • 1
  • 7
3
votes
1 answer

c++ - Get size of a single element or element count allocated using operator new[]

Is there a way to get size of a single element or element count allocated using operator new[] ? What I mean: void* Object::operator new[](size_t size) { void *temp = ::operator new(size); //Get size of single element or count of elements…
EOG
  • 1,677
  • 2
  • 22
  • 36
3
votes
2 answers

Matlab create matrix from data of other matrix

I have one matrix *u_test* that contains the data from my test set. It's formats is like that: X y value 1 3 5.0 1 6 3.4 4 3 2.0 I want to create a matrix test from *u_test*, so that the value of the rating is in it correct position, for…
tfcstack
  • 138
  • 1
  • 10
3
votes
2 answers

How to create a text file, and naming it with a text box or variable

Hi im very new to c# so apologies for this. Im trying to create a text file to save customers details. But i want to name the text file by the surname. I.e myfile.txt. Im sure im close, but missing something when it comes to changing the…
user1735367
  • 119
  • 1
  • 2
  • 6