The Finder or System Events which is my preferred choice is able to give us the useful infos about items.
set anObject to (path to desktop as text) & "deselect Numbers.scpt"
set anotherObject to (path to desktop as text) & "Versions as Recovery Tool 9&13"
tell application "System Events"
properties of disk item anObject
(* {
short version:"",
container:folder "SSD 500:Users:<yourAccount>:Desktop:" of application "System Events",
path:"SSD 500:Users:<yourAccount>:Desktop:deselect Numbers.scpt",
file type:"osas",
volume:"SSD 500",
physical size:20480,
id:"deselect Numbers.scpt,-100,1454963",
displayed name:"deselect Numbers.scpt",
busy status:false,
kind:"AppleScript",
creator type:"ToyS",
version:"",
name extension:"scpt",
POSIX path:"/Users/<yourAccount>/Desktop/deselect Numbers.scpt",
name:"deselect Numbers.scpt",
modification date:date "vendredi 13 février 2015 17:43:43",
size:16794,
class:file,
type identifier:"com.apple.applescript.script",
default application:alias "SSD 500:Applications:Utilities:Script Editor.app:" of application "System Events",
package folder:false,
creation date:date "vendredi 13 février 2015 16:37:55",
stationery:false,
visible:true,
product version:""}*)
properties of disk item anotherObject
(* {
name extension:"",
volume:"SSD 500",
package folder:false,
class:folder, modification date:date "samedi 8 novembre 2014 22:29:36",
physical size:missing value,
displayed name:"Versions as Recovery Tool 9&13",
path:"SSD 500:Users:<yourAccount>:Desktop:Versions as Recovery Tool 9&13:",
POSIX path:"/Users/<yourAccount>/Desktop/Versions as Recovery Tool 9&13",
container:folder "SSD 500:Users:<yourAccount>:Desktop:" of application "System Events",
id:"Versions as Recovery Tool 9&13,-100,1454231",
size:missing value,
busy status:false,
visible:true,
name:"Versions as Recovery Tool 9&13",
creation date:date "vendredi 13 juin 2014 16:57:29"} *)
end tell
tell application "Finder"
properties of alias anObject
(*
{class:document file,
name:"deselect Numbers.scpt",
index:191,
displayed name:"deselect Numbers.scpt",
name extension:"scpt",
extension hidden:false,
container:folder "Desktop" of folder "<yourAccount>" of folder "Users" of startup disk of application "Finder",
disk:startup disk of application "Finder",
position:{-1, -1},
desktop position:{742, 127},
bounds:{-33, -33, 31, 31},
kind:"AppleScript",
label index:0,
locked:false,
description:missing value,
comment:"",
size:16794,
physical size:20480,
creation date:date "vendredi 13 février 2015 16:37:55",
modification date:date "vendredi 13 février 2015 17:43:43",
icon:missing value,
owner:"<yourAccount>",
group:"(inconnu)", CAUTION, it's localized
owner privileges:read write,
group privileges:read only,
everyones privileges:read only,
file type:"osas",
creator type:"ToyS",
stationery:false,
product version:"",
version:""}*)
properties of alias anotherObject
(*
{class:folder,
name:"Versions as Recovery Tool 9&13",
index:127,
displayed name:"Versions as Recovery Tool 9&13",
name extension:"",
extension hidden:false,
container:folder "Desktop" of folder "<yourAccount>" of folder "Users" of startup disk of application "Finder",
disk:startup disk of application "Finder",
position:{-1, -1},
desktop position:{1222, 49},
bounds:{-33, -33, 31, 31},
kind:"Dossier",
label index:3,
locked:false,
description:missing value,
comment:"",
size:missing value,
physical size:missing value,
creation date:date "vendredi 13 juin 2014 16:57:29",
modification date:date "samedi 8 novembre 2014 22:29:36",
icon:missing value,
owner:"<yourAccount>",
group:"(inconnu)", CAUTION, it's localized
owner privileges:read write,
group privileges:read only,
everyones privileges:read only,
container window:container window of folder "Versions as Recovery Tool 9&13" of folder "Desktop" of folder "<yourAccount>" of folder "Users" of startup disk of application "Finder"}*)
end tell