This was based on my research.
Convert the integer to binary and 1 denotes permissions are set and 0 other wise.
Permission attributes from top to bottom to be mapped to bits Right to Left
SQL : Select Id, Agid, dec2bin(Doc_Perms) From Arsagperms
Oracle Function :
CREATE OR REPLACE FUNCTION dec2bin (N in number) RETURN varchar2 IS
binval varchar2(64);
N2 number := N;
BEGIN
while ( N2 > 0 ) loop
binval := mod(N2, 2) || binval;
N2 := trunc( N2 / 2 );
end loop;
return binval;
END dec2bin;