-2
votes
0answers
43 views

What can an algorithm look like that chooses appropriate images or songs?

My goal is to automatically create a slideshow of images if either a directory or images or an audio file is given. In the former case, software should find an appropriate audio file from a library. ...
0
votes
2answers
17 views

Design of object alias

Suppose you develop an interpreter or file system. There are objects, like variables, procedures and files in some environment. They have a name and content (variable has current value, procedure has ...
1
vote
0answers
27 views

Why covariance is forbidden for abstract class in C#

I've been digging in covariance and contravariance in C# and there is one thing I could not manage to understand. C# (AFAIK, as of 4 version) allows one to declare the covariant or contravariant ...
0
votes
0answers
9 views

Spring-Jersey contexts relation

Can somebody explain in simple words what are the differences and how do they relate, between the Spring context and Jersey context, HK2, servlet containers, filters, etc, in a webapp? How are their ...
-3
votes
1answer
25 views

Voice control of wheelchair

I'm working on a project to control a wheelchair by voice. But I'm an amateur programmer and have no knowledge how to write a code for voice control. So I wanted to know if it is possible for me to ...
-2
votes
0answers
15 views

What do we mean by task driven programming language

I was looking at C# language's wiki page and it is multi-paradigm language, one of them is Task Driven paradigm. I did not get any information from wiki for this. So my question is, what is task ...
-3
votes
0answers
11 views

adding menu and sub menus in context menu using javascript and ajax [on hold]

I want to add menus and submenus with link in context menu using javascript and ajax. If any solutions please share
2
votes
1answer
40 views

Why are triggers seen as a last resort to solve multiple paths in cascading deletes?

There is a problem using ON DELETE CASCADE on foreign keys in a SQL database if there are multiple paths from the root foreign key to the leaf. The way around this seems to be to replace the ON DELETE ...
0
votes
0answers
28 views

async/await, what is the purpose of async keyword? [duplicate]

Consider this sample taken from MSDN article about the subject async Task<int> AccessTheWebAsync() { // You need to add a reference to System.Net.Http to declare client. HttpClient ...
-5
votes
1answer
29 views

App development [on hold]

Almost searched everywhere and still puzzled with the question that how to get started with app development? I've few questions shortlisted. if anyone could help me out then it would be kind enough. ...
-3
votes
0answers
35 views

Is the book “How Tomcat Works” still worth reading, despite being published in 2004? [on hold]

How Tomcat Works Paperback – April, 2004 by Budi Kurniawan (Author), Paul Deck (Author) It deals with Tomcat 4 and 5, but appears well written - simple and concise. Is it nevertheless too outdated ...
-4
votes
0answers
29 views

Difficulties Facing in Learning [on hold]

I am studying final year in graduation. Recently I got place in a cloud computing based company. They hired me based on my communication skills. I don't even know the basics in cloud computing. What ...
5
votes
2answers
70 views

Doesn't returning a Collection as Unmodifiable / Immutable unnecessarily break method scope?

Let's say I create a Collection in an instance method. I do not assign that reference to any instance variables. Rather, I just return it to the invoker. Then, I exit. Now, the only thing with a ...
-1
votes
0answers
11 views

Clozure CL Cannot install on Mac App Store

I have been trying to install Clozure CL from the Mac App store, but have been faced with "Unknown Error" message, followed by "We Could not complete your request". This error appears when I click on ...
-1
votes
0answers
8 views

Read PCAP: memory error with Python DPKT

I am trying to read PCAP file in python 2.7.10. The code is:---> import dpkt f = open('testbed-11jun.pcap') pcap = dpkt.pcap.Reader(f) for ts, buf in pcap: print ts, len(buf) But I got this ...
0
votes
0answers
18 views

merge vs rebase pull requests on github

I am actively working on a two person project with very few longstanding feature branches (longest existing branch is 3 weeks). I have spent the afternoon trying to understand merge vs rebase and ...
-5
votes
0answers
25 views

I cant even traverse a tree, How can i build an mobile app? [on hold]

i have experience in programming c++ in robotics. But i have not touched on binary tree for a while because i dont need it in my application. Does building an mobile app requires knwledge of tree, ...
-1
votes
0answers
21 views

Problem with Solving System of Equations [on hold]

I am working on a crank-nicolson scheme for solving the Allen-Cahn equation using MATLAB. Below is the code that I have written, but I keep on getting the warning of matrix is singular to working ...
0
votes
0answers
17 views

Java dom parser for graphml file

I'm trying to do a program that receive a graphml file and ought to create all the necessary java objects according to the content of the parsed graphml file with the following Java code: public ...
-1
votes
0answers
26 views

Short code command to send a bill in .pdf or even .txt file format [on hold]

I'm building a website similar to opentable.com but on a much smaller scale for a much smaller market. So I don't have the budget to make a complete solution like opentable has, that is, I don't have ...
2
votes
2answers
55 views

REST API - omitted properties in POST request: How should they be handled?

Given the following scenario: Teacher entity { "id": "1234", "name": "Mr. Didactic", "Subject": "History", "Classroom": "1A" } REST API endpoint: /teacher/id/1234 Let's say I submit ...
0
votes
1answer
25 views

How to compute Pricing of Product & Product Options based on User Input and Pricing from Database?

I am building a service for pricing options of a product and for pricing the product itself when product has various options. Example User selects some X options out of Y options available, where X ...
0
votes
0answers
25 views

Finding types in TypeScript

I'm using a lot of implicit any in TypeScript. I don't quite understand how to decipher a TSD file in order to get the correct type when building off a library like express or angular. Is there a way ...
1
vote
4answers
90 views

Will returning an enum, instead of String, be too restrictive here:

Currently, there are only 3 possible publishers. I might want to add some more in the future: interface NewsArticle { enum Publisher { NYPost, ChiTribune, LATimes } Publisher getPublisher(); ...
1
vote
1answer
36 views

Android continually checking Internet, Bluetooth and GPS status?

In my app I want the ability to continually check for Internet, Bluetooth and GPS status (if one is off/on). I need each of these to be on at all times for my application to work effectively. For ...
1
vote
2answers
85 views

Why use JSON dataset rather than SQL Query?

A colleague was asking me to explain a system information flow, as they are having problems with the wrong information being presented. It seems that what they have created is a custom built website, ...
1
vote
3answers
131 views

What was the first language that allowed a class to contain a member of it's own type

So, I had to create a class that had a member of it's own type. I looked into why this was possible, which is fascinating. Reading the answer, I find that a lot of work had to go into making this ...
-1
votes
0answers
34 views

Best many to many match and sort algorithm

Im looking for best algorithm to match and sort many to many values I have "book" which have many orders in many stacks (max capacity of stack is for example 10). Each orders have many products. Each ...
0
votes
1answer
29 views

Concurrent languages and non-concurrent dependencies

We had a bug caused by ruby workers (4 processes, 1 thread each) doing batching records using a legacy mongodb as the store. The race condition was around whether the batch was full or not; with one ...
0
votes
0answers
26 views

Change API response with minimum code changes

My Application is built on Laravel and currently has the following components : Models Dictionary Word Controllers DictionaryController WordController It's a JSON API, so views are nothing ...
4
votes
2answers
81 views

Compile-time checking for NULL initialized std::string

This is sort of the complementary question to How to best protect from 0 passed to std::string parameters?. Basically, I'm trying to figure out whether there is a way to have the compiler warn me if a ...
-4
votes
0answers
30 views

Is the power scriptable? [on hold]

Like for example, if computername script = 0 then computername script = 1, is that at all possible to keep the computer on? I also need the script in powershell format.
1
vote
0answers
28 views

Is this a good use of routes in MVC?

In the time I've spent working with MVC (ASP.NET MVC to be specific) I've found very few situations where I've needed to use custom routing. In my most recent project I came across such a situation. I ...
0
votes
1answer
45 views

Ruby: Abusing mixin

I'm currently working with some code that IMO has abused ruby's mixin features. Given that I'm new to ruby, I wonder if MO in IMO is correct or not. My primary question is what makes more sense (and ...
-2
votes
2answers
108 views

How do you hash 4 doubles into a size_t?

I have bounding boxes the key type. Box { double mins[2]; double maxs[2]; } And I want to have Box as the key type in the D programming language, so I have to implement: size_t toHash() const ...
0
votes
0answers
27 views

Is it a common pattern in Python to have instance variables assigned in a constructor start with an underscore?

I recently started using UtilSnips, a Vim plugin allowing for a certain level of automation while coding by using template-like code snippets for common code fragments (class and function definitions, ...
4
votes
5answers
444 views

Why do so many languages restrict string literals to a single source line? [on hold]

In, for example, the Bash scripting language, the following creates a string called $VAR which begins at the first " quote and continues until the next unescaped " quote. $VAR=" hello world! ...
0
votes
1answer
64 views

Relicensing GPL to more permissive license

I have been developing a GPL GUI application for many years by myself in my free time. I have been approached by a company who want to use my code as part of a propitiatory product. This would require ...
1
vote
1answer
41 views

How to find the cause of an exception in async code

I often see myself trying to follow my own code to find out where the exception came from. The typical example is when some parsing fails, and I catch the execption. Then I spend a ridiculous amount ...
0
votes
3answers
85 views

Including both “careful” and “dangerous” versions of a function in a library/module

I'm writing some code that I've decoupled off into a module of its own, and even though I'm most likely the only person who will use it, I'm trying to think as if I might not be. The functions in this ...
-4
votes
0answers
19 views

Asynchronous method to search and download a file by FTP connection [on hold]

I'm developing a Java desktop application. I need an asynchronous FTP method to search repeatedly (for example, every 2 seconds interval) if exists a new file on a web server and, if so, it downloads ...
0
votes
0answers
65 views

Can this be further normalized? [migrated]

I have to define a system where we will be storing Image data and which can have an arbitrary number of attributes for the Image added per client. I have designed the following table Image ImageID ...
-6
votes
0answers
28 views

What should be changes in following code to perform search and modify operation on file? [on hold]

void modify() { FILE *f1; struct Phnbk P; int id; clrscr(); f1=fopen("new1.txt","r+"); if(f1==NULL) { printf("\nError while opening file"); exit(0); } printf("\nEnter Contact ID to modify ...
-5
votes
0answers
38 views

To check images are duplicate or not

I want code for checking images are duplicate or not in C++ (MFC) (by using various techniques not only by getpixel)? I did by getpixel but I want to check for multiple images.
1
vote
0answers
28 views

Designing a web based smart card publisher

I'm working on an application that's supposed to have a web based GUI where you can insert some data. That data will be saved in persistent storage and a hex number generated and stored alongside. ...
0
votes
1answer
53 views

Simple React application design

I have a very simple app that lets you log in and then displays a dashboard. The design process with React and Redux is very simple : I have two React components : Login and Dashboard I store a ...
0
votes
1answer
66 views

Calculating pay based on hours worked

I am developing a simple payroll with .net and sql server-2008 these options. There are currently three categories of payment types, Salary = fixed monthly salary Commission = percentage of total ...
1
vote
0answers
79 views

Why are there still companies recruiting for compiler positions? [on hold]

The way I see it, all programming languages already have at least one compiler already built for them, and they are either open source or an established organisation is maintaining them. So why is it ...
0
votes
2answers
16 views

Secure authentication using JWT

I read about JWT and how they can provide secure authentication for calling api routes over http. I naively implemented it and here is how it goes : a client posts username and password to a login ...
-3
votes
4answers
123 views

Why do we add instance methods to classes? [on hold]

Rewrite of the Question: Is there a technical reason why we are not using static methods instead of instance methods. Technical reasons are for example: Performance or added type-safety. I reason ...

15 30 50 per page