Error:(53, 18) java: non-static method review() cannot be referenced from a static context. plss help!

package com.JatinMalhotra;

public class Main { public class car{ String name; int cylinders; int wheels; public car(String name,int cylinders,int wheels){; this.cylinders=cylinders; this.wheels=wheels; }

    public String getName() {         return name;     }      String review(){         return "No review for this car";     }   } public class Audi extends car{     public Audi(){          super("Audi",2,5);     }      @Override     String review() {         return "A Classic Car";     } } public class Maruti extends car {     public Maruti() {         super("Maruti800", 1, 4);      }      @Override     String review() {         return "An oldie with low performance";     } }  public static void main(String[] args) {      System.out.println("Enter the number to see car review:");     **car Car= **Review();****     System.out.println("The car is :"+Car.getName()+"its review is"; }   public  car Review(){     int n=(int)(Math.random()+1);      switch(n){         case 1: return new Audi();         case 2:return new Maruti();         default:return null;       }  } 


create 10 static banners in any size for $2

i will create 10 static not animated banners in gif or jpeg or png format with same design in 10 different sizes in your choice (standart size) 468 x 60 Full Banner728 x 90 Leaderboard336 x 280 Square300 x 250 Square250 x 250 Square160 x 600 Skyscraper120 x 600 Skyscraper120 x 240 Small Skyscraper240 x 400 Fat Skyscraper234 x 60 Half Banner180 x 150 Rectangle125 x 125 Square Button120 x 90 Button120 x 60 Button88 x 31 Button If need any other details don’t hesitate to ask

by: jawadi19
Created: —
Category: Banner Ads
Viewed: 202

Editing static blocks problem when saving

I have Magento website, everything was fine, website wasnt edited in a year and when I tried to edit some existing static block and save or save and continue editing I am returned in CMS/Static Blocks panel and no changes are made. It allows me to create new static block, but when I copy paste code from existing old block same happened. What I noticed when playing with blocks when I copy/paste code from existing block in new block for example:

 <div id="banner-slider-demo-2-new" class="owl-carousel owl-theme owl-middle-narrow owl-banner-carousel">     <div class="item" style="background:url({{media url="wysiwyg/porto/homepage/slider/02/13_new.jpg"}})  

Cant save the new created block. When I remove word “style” everything is ok and block is saved. It happen with all lines with “style”. Code is not proper without “style” but block is saved. I flushed everything, deleted cache, same happened. In system.log I found error that repeats 20 times per day in last 12 months:

2019-05-20T16:27:25+00:00 ERR (3): Warning: Invalid argument supplied for foreach() in /home/fedorsoaps/public_html/app/code/local/Smartwave/Socialfeeds/Helper/Data.php on line 79

And, line 79 in Data.php is:

 79    foreach ($  doc->getElementsByTagName('ul')->item(0)->childNodes as $  child) {         $  raw = $  doc->saveXML($  child);         $  li = preg_replace("/<li[^>]+\>/i", "", $  raw);         $  peopleList[$  i] = preg_replace("/<\/li>/i", "", $  li);         $  i++; 

Meanwhile website frontend is working normally but I cant make any changes. I am not coder, just basic Magento installer, thanks for any help.

Auto-generating some type annotations in Python with static program analysis

There are some tools like MonkeyType and PyAnnotate that can give you type annotations in Python by runtime tracing. What is the best way to go about automatically generating some useful type annotations this without actually executing the Python programs, i.e. in a static way?

ffmpeg static builds from john requires libraries?

I’m trying to run ffmpeg with ubuntu 18.04. I downloaded latest git build from

But when I try to run any ffmpeg command, it complains about a lot of missing libraries like 

Just to name a few…isn’t the point of a static build to not require anything else to run? Or am I doing something wrong?

I feel like there are endless libraries I have to install to make it work. Is there a way to just install everything it needs?

And I believe most libraries in the repos would be super old right?

Can we serve static files from Tomcat FASTER than NginX/Apache?

The following data was from testing on my own windows machine(SSD) on localhost. When I download static content from Nginx, I get upto 120-140 MBps(I am sure it can optimized further. Nginx actually claims it can reach a throughput of upto 0.98 Gbps). And this was being done, with almost negligible increase in cpu/memory consumption increase. I have tried to do the same in tomcat, and the max speed when downloading files is upto 25 Mbps. Also, this consumes 15-25% of cpu usage as per task manager. My machine has a SSD, so no, the file reading isn’t taking time or increasing cpu usage.

Can the file serving part be improved? I.E serving faster download speeds with lesser cpu consumption.

<Connector port="29022" protocol="org.apache.coyote.http11.Http11Nio2Protocol" useSendfile="true" connectionTimeout="300000"/> 

I am using Nio2 connector. Should I tweak any more of the connector settings, or use Nio/apr connector?

All file download requests are delegated to a threadpool using an asynchronous servlet call : request.setAttribute(“org.apache.catalina.ASYNC_SUPPORTED”, true);

The threads from the thread pool(thread pool size is 2) will serve each of the requests in a round robin fashion in a loop. In each loop iteration, the following code is executed to send about 8 KB(8192 Bytes).

if(bytesSent < toBeServedFileSize){     if(!buffer.hasRemaining()){         buffer.clear();,bytesSent);         buffer.flip();     }     int bytesToWrite = Math.min(buffer.remaining(), streamPacketSize);     byte[] byteAr = new byte[bytesToWrite];     for (int i = 0 ; i < bytesToWrite ; i++){byteAr[i] = buffer.get();}     //I'm guessing below is the most cpu intensive line     os.write(byteAr);     //I am guessing above is the most cpu intensive line     bytesSent += bytesToWrite; } 

The whole purpose of this exercise is to both authenticate and authorise the file download requests. I think serving static content from apache/NginX don’t have good solutions to address this requirement. Suggestions and alternate solutions are welcome.

How to troubleshoot internal DNS resolution (Windows DNS server) pointing to a local server with a static internal IP address

To better explain the set up

  • I have a Debian server in a private network with a static IP.
  • There is a windows AD server that resolves DNS for clients internally.
  • A domain name is already registered and a public IP is pointed to the server
  • AAA record mapping to the static IP internally has been done (as i have been told)

Basically when you type in the domain name it does not reach the debian sever.

I dont have access to anything in the private network except the debian server.

How do i troubleshoot this issue? this web server was working before so it is not the firewall.

I can provide any required files from the debian server, please help out or even a helpful link would be fine.


Magento 2.3 : Css files not generating while static content deploy

In File.php line 150:

The contents from the

"D:/projects/directory/m2/pub/static/frontend/Smartwave/porto/en_US/css/styles-l.css" file can't be read. Warning!file_get_contents(D:/projects/directory/m2/pub/static/frontend/Smartwave/porto/en_US/css/styles-l.css): failed to open stream: No such file or directorysetup:static-content:deploy [-f|--force] [-s|--strategy [STRATEGY]] [-a|--area [AREA]] [--exclude-area [EXCLUDE-AREA]] [-t|--theme [THEME]] [--exclude-theme [EXCLUDE-THEME]] [-l|--language [LANGUAGE]] [--exclude-language [EXCLUDE-LANGUAGE]] [-j|--jobs [JOBS]] [--symlink-locale] [--content-version CONTENT-VERSION] [--refresh-content-version-only] [--no-javascript] [--no-css] [--no-less] [--no-images] [--no-fonts] [--no-html] [--no-misc] [--no-html-minify] [--] [<languages>...] 

Auto-generating type annotations in Python with static program analysis

There are some tools like MonkeyType and PyAnnotate that can give you type annotations in Python by runtime tracing. Is there any way to do this without actually executing the Python programs, i.e. in a static way? I’d like to do this on a large scale for many different Python files, and I don’t think it’s feasible for me to run all of them (security and time issues).