url 모듈url을 다룰 수 있는 모듈로 url 모듈과 querystring 모듈이 있습니다.var url = require('url');url은 다음과 같이 url 정보를 다룹니다.// 주소 문자열을 URL 객체로 만들기var curURL = url.parse('https://m.search.naver.com:443/search.naver?query=steve+jobs&where=m&sm=mtp_hty');// URL 객체를 주소 문자열로 만들기var curStr = url.format(curURL);console.log('주소 문자열 : %s', curStr);console.dir(curURL); //URL 정보를 담고 있는 객체주소 문자열 : https://m.search.naver.com:443/..
NodeJS
2017. 12. 30. 17:04
[Node.js] os모듈 사용법
OS모듈시스템 정보를 알려줍니다. 시스템 정보를 알아낼 때 유용합니다.모듈 가져오는 방법var os = require('os');사용방법var os = require('os');console.log('호스트명 : ' + os.hostname()); //운영체제 호스트 네임 반환console.log('시스템의 메모리 : %d / %d',os.freemem(), os.totalmem()); //유휴메모리 / 총 메모리console.log('------cpu 정보-----------------------'); //cpu 정보 출력console.log(os.cpus()); //cpu 정보 출력console.log('------네트워크 인터페이스 정보----------- ');console.log(os.netwo..
전산학개론
2017. 11. 2. 22:52
[개념정리] API(Application Programming Interface) 란??
API란?컴퓨터공학을 전공하다 보면 API라는 말을 많이 접하게 됩니다.API란 무엇일까요?먼저 API는 Application Programming Interface 의 약자입니다.한국말로 풀이하면 어플리케이션을 프로그래밍할 때 쓰이는 인터페이스(Interface) 라는 뜻이지요.어플리케이션과 프로그래밍이라는 말은 아실겁니다.그럼 어플리케이션을 개발할 때 쓰이는 Interface란 무엇일까요?먼저 Interface라는 단어의 뜻을 아셔야 합니다.Interface = inter + face 입니다.inter는 '~ 사이의', '상호간의' 라는 뜻을 가지고 있습니다.inter가 들어간 단어들을 볼까요?interstellar(항성간의) = inter + stellar(별의)international(국제적인) ..